[Fusionforge-general] Improvements on the mediawiki-plugin

Roland Mas lolando at debian.org
Fri Mar 19 11:32:38 CET 2010


Olaf Lenz, 2010-03-18 09:54:25 +0100 :

[...]

> What has changed up to now are the following things:
>
> * I have written create-wikis.php and drop-wiki.php (in PHP), based on
> the corresponding shell-scripts. Implementing it in PHP has the
> advantage that it can use all the existing mechanisms already
> available for PHP (DB connection, cronjob log, ...) which caused some
> problems in the shell script. create-wikis.php is still missing the
> distinction between public and private projects, but otherwise it
> works fine.

  Great.  The initial implementation in shell was meant to be only that:
an initial implementation.  Glad to see someone converted it to
something more sustainable :-)  The public/private thing will need to be
fixed, but the PHP reimplementation is great.

> * In general, I have seen to it that there are (almost) no hard-coded
> paths in any of the scripts anymore, which is extremely useful when
> installing FF in non-standard locations. There is only a single place
> left, namely LocalSettings.php, where it loads /etc/gforge/local.inc,
> which is hard-coded currently, as I had no better idea how to find the
> file. This has some implications for the unified config system that we
> might have to discuss, probably tomorrow.

  Excellent.

> * Instead of providing the LocalSettings.php for the projects inlined
> in create-wikis, I have made it an independent file, that you can find
> in plugins/mediawiki/etc/ProjectSettings.php and that is copied to the
> project dir by create-wikis. Also, create-wikis is prepared such that
> the forge admin can provide
> /etc/gforge/plugins/mediawiki/ProjectSettings.php instead, which
> allows him to customize the project settings.

  Good.

> * Instead of expecting the links to the mediawiki source files in
> $sys_opt_path/plugins/mediawiki/www, the plugin now expects the files to
> be found in $sys_var_path/plugins/mediawiki/master, while the project
> files (ProjectSettings.php and images/) are found in
> $sys_var_path/plugins/mediawiki/projects .

  This will probably require changes in the packaging (or at least in
the Apache config).

> The reason for this is that (a) I don't like the idea that the admin
> has to change anything below $sys_opt_path to get FF running, and (b)
> I would prefer it if these links etc. would be created by an init
> script, which I will write tomorrow. This also allows that an admin
> can again provide his own customized LocalSettings.php file in
> /etc/gforge, instead of having to modify the FF-provided one.

  Init script?  I hope this isn't a boot script, as I think they should
be done by the packaging or the installation script.

  I have another objection: you moved the per-project wiki data
directory from /var/lib/gforge/plugins/mediawiki/wikidata/$project to…
somewhere else ($mw_var_path doesn't seem to be defined).  I'd prefer to
keep the existing path, or at least make it possible to have it under
/var/lib/gforge/plugins/mediawiki/ with an appropriate value for
$mw_var_path.

  Apart from these problems, I like the patch.  If the bugs could be
fixed soon, I'm almost tempted to include it in 5.0, too, so as to
prevent a wide diffusion of my initial implementation and limit the
number of migrations from one directory to another.

Roland.
-- 
Roland Mas

Meaning lies as much / In the mind of the reader / As in the haiku
  -- in Gödel, Escher, Bach: an Eternal Golden Braid (Douglas Hofstadter)




More information about the Fusionforge-general mailing list