User:Mike.lifeguard/remote.js
Appearance
Note: After publishing, you may have to bypass your browser's cache to see the changes.
- Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
- Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
- Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5.
if (mw.config.get('wgUserName') == 'Mike.lifeguard') {
//apparently only I like this :(
mw.loader.load('//meta.wikimedia.org/w/index.php?title=User:Mike.lifeguard/remote.css&action=raw&ctype=text/css', 'text/css');
}
function userIsInGroup (group) {
return $.inArray(group, mw.config.get('wgUserGroups')) != -1;
}
function userIsInGlobalGroup (group) {
return $.inArray(group, mw.config.get('wgGlobalGroups')) != -1;
}
function importAnyScript(lang,family,script) {
mw.loader.load('//' + encodeURIComponent(lang) + '.' + encodeURIComponent(family) + '.org/w/index.php?title=' + encodeURIComponent(script) + '&action=raw&ctype=text/javascript');
}
/**
* Forces left-to-right layout and editing on RTL wikis.
* @see https://meta.wikimedia.org/wiki/Force_ltr
* @update-token [[File:pathoschild/forceltr.js]]
*/
mw.loader.load('//tools-static.wmflabs.org/meta/scripts/pathoschild.forceltr.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/sixTabs.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/addTools.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/removeSpam.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/regexliFilter.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/rangeContribs.js');
if (!userIsInGroup('oversight')){
//this breaks revision deletion :(
importAnyScript('meta','wikimedia','User:Mike.lifeguard/fixCompare.js');
}
if (userIsInGroup('sysop')||userIsInGroup('rollbacker')||userIsInGlobalGroup('Global_rollback')||userIsInGlobalGroup('steward')) {
//only local sysops, rollbackers, global rollbackers and stewards can make use of these scripts
importAnyScript('meta','wikimedia','User:Erwin/xwikirollback.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/modRollback.js');
}
if (userIsInGroup('sysop')||userIsInGlobalGroup('steward')) {
//only stewards or local sysops can make use of this script
/**
* Ajax sysop
* @see https://meta.wikimedia.org/wiki/Ajax_sysop
* @update-token [[File:pathoschild/ajaxsysop.js]]
*/
mw.loader.load('//tools-static.wmflabs.org/meta/scripts/pathoschild.ajaxsysop.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/autoDelete.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/blockOptions.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/enhancedUndelete.js');
importAnyScript('meta','wikimedia','User:Mike.lifeguard/massBlock.js');
}