install.php: Allow extensions and skins to be specified
authorTim Starling <tstarling@wikimedia.org>
Wed, 19 Sep 2018 05:43:14 +0000 (15:43 +1000)
committerLegoktm <legoktm@member.fsf.org>
Wed, 10 Oct 2018 03:26:14 +0000 (03:26 +0000)
commit5e9ada58821e7e54fed9fed5dd2b1e7968967067
treeaec786fd76ba53d5585b63a4a658b7735073b48a
parente94964989dc3508ccfcd4f6d71a912b98a75a5be
install.php: Allow extensions and skins to be specified

Allow the extensions and skins installed by maintenance/install.php to
be customised using --skins= and --extensions=. If the argument is
am empty string then no extensions/skins are installed. For backwards
compatibility, the default is to install all skins, but to install all
extensions only if --with-extensions is given.

The new CLI options may be specified multiple times, but for
convenience, comma-separated lists can also be used.

Also:
* Rename $option to $options
* If an extension has a dependency error, propagate the very readable
  error message generated by ExtensionRegistry back to the user.
* Split getExtensionInfo() from the loop body of findExtensionsByType(),
  so that CliInstaller can use it to validate its parameters and get
  error messages.
* I didn't like the idea of removing the "s" from the directory name in
  order to construct the JSON file name, so I split
  findExtensionsByType() from findExtensions(), with the former not
  having this hack. In findExtensions(), make the previous assumption
  that the directory name is always "extensions" or "skins" explicit,
  throwing an exception if it is otherwise.

Change-Id: Id0fb63cd4e61a047ef3396ee1c38d6073dfc7fd1
includes/installer/CliInstaller.php
includes/installer/Installer.php
includes/installer/i18n/en.json
includes/installer/i18n/qqq.json
maintenance/install.php