User:Ale jrb/Scripts/iglooSettings.js
Appearance
< User:Ale jrb | Scripts
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with "importScript", "mw.loader.load", "iusc", or "lusc", take note that this causes you to dynamically load a remote script, which could be changed by others. Editors are responsible for all edits and actions they perform, including by scripts. User scripts are not centrally supported and may malfunction or become inoperable due to software changes. A guide to help you find broken scripts is available. If you are unsure whether code you are adding to this page is safe, you can ask at the appropriate village pump. This code will be executed when previewing this page. |
Documentation for this user script can be added at User:Ale jrb/Scripts/iglooSettings. |
/* ======================================================== *\
** igloo frontend manager - settings
** tracker: [[User:Ale_jrb/Scripts/igloo]]
\* ======================================================== */
// this page simply defines some global code settings for igloo
function ig () {
// version settings
this.version = '1.0m-c';
this.build = 'alpha';
this.versionString = 'version: '+this.version+'; build: '+this.build;
this.developerMode = true;
this.firstRun = true; // set true to enable displaying of first run info & welcome
// url settings
this.remoteHost = 'http://bots.wmflabs.org/~alejrb/igloo/';
this.articleBase = mw.config.get('wgServer') + mw.config.get('wgArticlePath').substr ( 0, ( wgArticlePath.length - 2 ) );
this.localBase = 'User:Ale_jrb/Scripts/igloo/';
this.rootApi = wgScriptPath + '/api.php';
// interface settings
this.hookInterface = true;
this.enableFeedColour = true;
this.enableWindowColour = false;
this.profFilter = true;
this.histWinTimeout = 0.8;
this.blockKeys = true;
this.dynamicBlockKeys = 'default';
this.preloadInterface = true;
this.diffFontSize = 10;
// program settings
this.serverTimeout = 10;
this.updateTime = 3;
this.updateQuantity = 15;
this.hideOwn = false; // hide own edits from queue
this.defaultUserScore = 0.5;
this.maxHistory = 20;
this.permitPingfails = 4;
// user data - this data is always either overwritten by the server or ignored
this.lastConnectIp = 0;
this.lastConnectTime = 0;
this.totalSessions = 0;
this.iglooFlags = 'noflags';
// iglooNet settings
this.recheck = true; // investigate even if we already have data
this.commitToIgNet = true; // whether igloo can attempt to commit its findings to iglooNet
this.commitWhen = 0; // how often igloo should attempt to investigate a user (lower = more often)
// wiki settings
this.vandalTemplate = 'vandalism';
this.warningMessage = '{'+'{subst:uw-%MESSAGE%%LEVEL%|%PAGE%|2=The reverted edit can be found <span class="plainlinks">[%DIFF% here]</span>.}'+'}<!'+'-- igloo:%MESSAGE%%LEVEL% --'+'> ~~'+'~~';
this.warningSummary = 'Level %LEVEL% warning re. vandalism on [[%PAGE%]] (['+'[' + this.localBase.substr ( 0, this.localBase.length - 1 ) + '|GLOO]'+'])';
this.rollbackSummary = 'Reverted edits by [[Special:Contributions/$2|$2]] to last version by $1 (['+'[' + this.localBase.substr ( 0, this.localBase.length - 1 ) + '|GLOO]'+'])';
this.warningsOldAfter = 2; // days after which warnings are considered irrelevant
this.aiv = 'Wikipedia:Administrator intervention against vandalism';
this.aivWhere = 'appendtext';
this.aivIp = 'IPvandal';
this.aivUser = 'vandal';
this.aivMessage = '* {'+'{%TEMPLATE%|%USER%}'+'} - vandalism after final warning. ~~'+'~~';
this.aivSummary = 'Reporting [[Special:Contributions/%USER%|%USER%]] - vandalism after final warning (['+'['+this.localBase.substr(0, this.localBase.length-1)+'|GLOO]'+'])';
// customisation settings
this.updateLimit = 80;
this.notifyWarningDone = true;
this.promptRevertSelf = true;
this.enableUserFilters = false;
this.flagColours = [ '#ff8888', '#ffbbbb', '#ffffff', '#bbffbb', '#88ff88' ]; // v. dirty, dirty, neutral, clean, v. clean
this.enableFilters = true;
this.filterList = [];
// sysop only settings
this.mesysop = false; // iglooMain overwrites on load, if required
this.blockAction = 'prompt';
this.useAutoBlock = true;
this.blockTypes = { 'default' : 'subst:uw-vblock|time=%DURATION%|sig=yes', 'sharedipedu' : 'schoolblock|1=Blocked for %DURATION%.|sig=~~'+'~~', 'sharedippublic' : 'anonblock|1=Blocked for %DURATION%.|sig=~~'+'~~', 'sharedip' : 'anonblock|1=Blocked for %DURATION%.|sig=~~'+'~~' }; // if detected on the talk page, the autoblocker will try to use this template
this.blockIncrement = [ 'indefinite', '1 hour', '3 hours', '6 hours', '12 hours', '24 hours', '31 hours', '48 hours', '72 hours', '1 week', '2 weeks', '1 month', '3 months', '6 months', '1 year' ]; // recognised block length
this.blockDefault = 6; // the above block length to issue by default
this.blockSpecTemp = '1 month'; // non-default templates above will only be used when handling blocks greater than or equal to this setting
this.anonBlockSettings = '&anononly=&nocreate=&allowusertalk='; // this should take the form of an API block settings string, and will be attached to the api request (default string)
this.userBlockSettings = '&autoblock=&nocreate=&allowusertalk='; // this should take the form of an API block settings string, and will be attached to the api request (default string)
}
var iglooSettings = new ig ();