Extension:ExtensionStatus

MediaWiki extensions manual
ExtensionStatus
Release status: unmaintained
Implementation Special page
Description Checks the remote extension repositories for newer versions than installed on the wiki to determine the update status
Author(s) Moriel Schottlender (mooeypootalk)
Latest version 0.1.0 (2013-05-13)
MediaWiki 1.20.x
PHP 5.3+
Database changes No
License GNU General Public License 2.0 only
Download
README
Example Screenshots
extensionversion

The ExtensionStatus extension checks the remote extension repositories for newer versions than installed on the wiki to determine the update status.

To do so it goes over the list of installed extensions in the MediaWiki installation and checks if there are any later commits (changes to the code) in the remote repository. For the moment, the extension checks changes in front of a Gerrit repository only.

Development

edit

This extension is still under development -- testers are welcome!

There's a lot of potential in producing a system that can help users (both experienced and new) to check if their extensions require update, and even perform regular updates for them. For the moment, this extension is fairly basic, but this page will discuss some possibilities for future development and usage (feel free to contribute ideas in the talk page!)

Current Operation

edit

The current system extends the Special:Version page. It takes over the 'extension credits' section, and inserts a secondary process to test the available commits.

For each extension:

  • First, the local extension date is noted.
    • If git is available on the machine, the date is extracted from the local repository.
    • If git is unavailable or not installed, the system falls back to testing local file modification time.
  • The system tries to read the Gerrit repository's "summary" page.
  • If such page exists and returns results, the page is read for each commit
    • If a commit date is before the date of the local extension files, the operation stops.
    • Commits made by the Translation Bot are counted separately, and are skipped for content.
  • The commits are then returned as an array and are displayed in the Extensions table.

This operation is still somewhat slow, especially for large systems with many extensions. An alternative is now being researched. However, whatever alternative is used, should allow for same (or similar) functionality regardless of the availability of git in the system.

Screenshot

edit
 
Current screenshot of the Special:ExtensionStatus page

Future / To Do List

edit
 
Proposed Mockup
  • FASTER FASTER FASTER! Reading remote files per repository is slow. A new approach should be implemented.
  • Adding cache functionality
  • Changing from gerrit to the wikimedia GitHub mirrored repos
  • Redesigning the extension for better view and control
  • Allowing for upgrades from the extension page itself
  • Allowing the system to test repository outside of Gerrit.
  • Reading extension data from WikiApiary

Resources and Similar Projects

edit
  • Fetchrepo - Python script to automatically fetch repo files.

Installation

edit
  • Download and place the file(s) in a directory called ExtensionStatus in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php file:
    require_once "$IP/extensions/ExtensionStatus/ExtensionStatus.php";
    
  •   Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.