Wikipedia:Konfigurasjon for FlaggedRevs

Fra Wikipedia, den frie encyklopedi
Hopp til: navigasjon, søk

Konfigurasjon av FlaggedRevs slik at et oppsett på denne wikien tilsvarer engelsk Wikipedia.

Endring i wmf-config/InitialiseSettings.php[rediger kilde]

Dette er en endring i den eksisterende initialiseringen.

Tidligere kode
   'nowiki' => array(
       'patroller' => array( 'patrol' => true, 'autopatrol' => true, 'rollback' => true, 'unwatchedpages' => true, 'suppressredirect' => true, ),
       'autopatrolled' => array( 'autopatrol' => true, 'unwatchedpages' => true ),
   ),
Ny kode
   #'nowiki' => array(
   #    'reviewer' => array( 'patrol' => true, 'rollback' => true, 'unwatchedpages' => true, 'suppressredirect' => true, ),
   #    'editor' => array( 'autopatrol' => true, 'unwatchedpages' => true ),
   #),

Endring i wmf-config/flaggedrevs.php[rediger kilde]

Dette er et tillegg til den eksisterende konfigurasjonen.

Ny kode
elseif ( $wgDBname == 'nowiki' ) {
 
   # Override which namespaces we want to stabilize
   $wgFlaggedRevsNamespaces = array( NS_MAIN, NS_PROJECT );

   # Whitelist some pages
   #$wgFlaggedRevsWhitelist = array();

   # Show only on a per-page basis
   $wgFlaggedRevsOverride = false;

   # Possibly turn off the simple UI
   $wgSimpleFlaggedRevsUI = false;

   ### The English setup with a single status tag and one level
   # Only one tag with one level
   #$wgFlaggedRevTags = array(
   #    'status' => array( 'levels' => 1, 'quality' => 2, 'pristine' => 3 ),
   #);
   # Restrict autoconfirmed to flagging semi-protected
   #$wgFlagRestrictions = array(
   #    'status' => array( 'review' => 1, 'autoreview' => 1 ),
   #);
   ### or the Finish one with a single accuracy tag and several levels
   $wgFlaggedRevTags = array(
       'accuracy' => array( 'levels' => 3, 'quality' => 3, 'pristine' => 4 ),
   );
   $wgFlagRestrictions = array(
       'accuracy' => array( 'review' => 3, 'autoreview' => 2 ),
   );
   ### End

   # Restriction levels for auto-review/review rights
   #$wgFlaggedRevsRestrictionLevels = array( '', 'autoconfirmed', 'review' );
   #$wgFlaggedRevsRestrictionLevels = array( '', 'autoreview', 'review' ); // this is default?
   # Use flag "protection" levels
   $wgFlaggedRevsProtection = true;
   # Use current templates/files
   $wgFlaggedRevsHandleIncludes = FR_INCLUDES_CURRENT;
   # WP:FPPR trial quota
   $wgFlaggedRevsProtectQuota = 2000;

   # These are autopromoted editors
   $wgFlaggedRevsAutopromote = $wmfStandardAutoPromote;
   $wgFlaggedRevsAutopromote['days'] = 60; # days since registration
   $wgFlaggedRevsAutopromote['edits'] = 500; # total edit count
   $wgFlaggedRevsAutopromote['excludeDeleted'] = true; # exclude deleted edits from 'edits' count above?
   $wgFlaggedRevsAutopromote['spacing'] = 3; # spacing of edit intervals
   $wgFlaggedRevsAutopromote['benchmarks'] = 25; # how many edit intervals are needed?
   $wgFlaggedRevsAutopromote['recentContentEdits'] = 10; # $wgContentNamespaces edits in recent changes
   $wgFlaggedRevsAutopromote['totalContentEdits'] = 30; # $wgContentNamespaces edits
   $wgFlaggedRevsAutopromote['uniqueContentPages'] = 10; # $wgContentNamespaces unique pages edited
   $wgFlaggedRevsAutopromote['editComments'] = 5; # how many edit comments used?
   $wgFlaggedRevsAutopromote['email'] = false; # user must be emailconfirmed?
   $wgFlaggedRevsAutopromote['userpageBytes'] = 0; # if userpage is needed, what is the min size?

   # Group permissions for editor
   $wgGroupPermissions['editor']['autoreview'] = true;
   # Group permissions for reviewer
   $wgGroupPermissions['reviewer']['autoreview'] = true;
   $wgGroupPermissions['reviewer']['review']         = true;
   $wgGroupPermissions['reviewer']['stablesettings'] = true;
   # Group permissions for sysops
   $wgGroupPermissions['sysop']['autoreview'] = true;
   $wgGroupPermissions['sysop']['review']         = true;
   $wgGroupPermissions['sysop']['stablesettings'] = true;
   # Use 'editor' group
   $wgAddGroups['reviewer'][] = 'editor';
   $wgRemoveGroups['reviewer'][] = 'editor';
   $wgAddGroups['sysop'][] = 'editor';
   $wgRemoveGroups['sysop'][] = 'editor';
   # Use 'reviewer' group
   $wgAddGroups['bureaucrat'][] = 'reviewer';
   $wgRemoveGroups['bureaucrat'][] = 'reviewer';
}

Se også[rediger kilde]