[Fusionforge-commits] r8816 - in trunk/gforge/plugins/mediawiki: cronjobs www

Roland Mas lolando at libremir.placard.fr.eu.org
Fri Feb 12 13:11:46 CET 2010


Author: lolando
Date: 2010-02-12 13:11:46 +0100 (Fri, 12 Feb 2010)
New Revision: 8816

Modified:
   trunk/gforge/plugins/mediawiki/cronjobs/create-wikis.sh
   trunk/gforge/plugins/mediawiki/www/LocalSettings.php
Log:
Use the sysop group to grant Mediawiki rights to project admins

Modified: trunk/gforge/plugins/mediawiki/cronjobs/create-wikis.sh
===================================================================
--- trunk/gforge/plugins/mediawiki/cronjobs/create-wikis.sh	2010-02-12 09:41:03 UTC (rev 8815)
+++ trunk/gforge/plugins/mediawiki/cronjobs/create-wikis.sh	2010-02-12 12:11:46 UTC (rev 8816)
@@ -21,9 +21,6 @@
 \$wgEnableUploads = false;
 // Don't forget to "chown www-data $wdprefix/$project/images"
 
-// Edit permissions for group admins
-\$wgGroupPermissions['Administrators']['*']          = true;
-
 // Edit permissions for group members
 \$wgGroupPermissions['Members']['edit']          = true;
 \$wgGroupPermissions['Members']['createpage']    = true;

Modified: trunk/gforge/plugins/mediawiki/www/LocalSettings.php
===================================================================
--- trunk/gforge/plugins/mediawiki/www/LocalSettings.php	2010-02-12 09:41:03 UTC (rev 8815)
+++ trunk/gforge/plugins/mediawiki/www/LocalSettings.php	2010-02-12 12:11:46 UTC (rev 8816)
@@ -119,8 +119,8 @@
 		$user->loadGroups() ;
 		$current_groups = $user->getGroups() ;
                 if ($perm && is_object($perm) && $perm->isAdmin()) {
-                        if (!in_array ('Administrators', $current_groups)) {
-                                $user->addGroup ('Administrators') ;
+                        if (!in_array ('sysop', $current_groups)) {
+                                $user->addGroup ('sysop') ;
                         }
                         if (!in_array ('Members', $current_groups)) {
                                 $user->addGroup ('Members') ;
@@ -129,8 +129,8 @@
                                 $user->addGroup ('ForgeUsers') ;
                         }
                 } elseif ($perm && is_object($perm) && $perm->isMember()) {
-                        if (in_array ('Administrators', $current_groups)) {
-                                $user->removeGroup ('Administrators') ;
+                        if (in_array ('sysop', $current_groups)) {
+                                $user->removeGroup ('sysop') ;
                         }
                         if (!in_array ('Members', $current_groups)) {
                                 $user->addGroup ('Members') ;
@@ -139,8 +139,8 @@
                                 $user->addGroup ('ForgeUsers') ;
                         }
                 } else {
-                        if (in_array ('Administrators', $current_groups)) {
-                                $user->removeGroup ('Administrators') ;
+                        if (in_array ('sysop', $current_groups)) {
+                                $user->removeGroup ('sysop') ;
                         }
                         if (in_array ('Members', $current_groups)) {
                                 $user->removeGroup ('Members') ;




More information about the Fusionforge-commits mailing list