// Enable caching for resource loads, see [[User:SD0001/Making_user_scripts_load_faster]], @revision 6
if (!/\bnocache=\b/.test(location.href)) { // Don't enable if nocache=1 url parameter is given
let loadResource = (page, sitename, ctype) => {
page = page.replace(/special:mypage/i, 'User:' + mw.config.get('wgUserName'));
return $.get(
'https://' + sitename + '/w/api.php?titles=' + page + // page is already URL-encoded
'&origin=*&format=json&formatversion=2&uselang=content&maxage=86400&smaxage=86400' +
'&action=query&prop=revisions|info&rvprop=content&rvlimit=1'
).then((apiResponse) => {
let apiPage = apiResponse.query.pages[0];
if (apiPage.missing) {
return;
}
let content = apiPage.revisions[0].content;
if ((!ctype || ctype === 'text/javascript') && apiPage.contentmodel === 'javascript') {
let scriptTag = document.createElement('script');
scriptTag.innerHTML = content;
document.head.appendChild(scriptTag);
} else if (ctype === 'text/css' && apiPage.contentmodel === 'css') {
mw.loader.addStyleTag(content);
} else {
return $.Deferred().reject('Refused to load "' + page + '"@' + sitename + ': content type mismatch');
}
});
};
let getSiteTitle = (url) => {
let siteRgx = /^(?:(?:https:)?\/\/(.*))?\/w\/index.php/.exec(url),
titleRgx = /\btitle=([^=?&]*)/.exec(url);
if (siteRgx && titleRgx && /\baction=raw\b/.test(url) && /\bctype=/.test(url)) {
return [titleRgx[1], siteRgx[1] || mw.config.get('wgServerName')];
} else return null;
};
window.importScript = (page) => {
loadResource(encodeURIComponent(page), mw.config.get('wgServerName'), 'text/javascript');
};
window.importStyleSheet = (page) => {
loadResource(encodeURIComponent(page), mw.config.get('wgServerName'), 'text/css');
};
let oldMwLoaderLoad = mw.loader.load;
mw.loader.load = function(url, type) {
let linkParts = getSiteTitle(url);
if (linkParts) {
loadResource(linkParts[0], linkParts[1], type);
} else {
oldMwLoaderLoad.apply(mw.loader, [...arguments]);
}
};
let oldMwLoaderGetScript = mw.loader.getScript;
mw.loader.getScript = function(url) {
let linkParts = getSiteTitle(url);
if (linkParts) {
return loadResource(linkParts[0], linkParts[1], 'text/javascript');
} else {
return oldMwLoaderGetScript.apply(mw.loader, [...arguments]);
}
};
}
importScript('User:GeneralNotability/mark-locked.js'); // Backlink: [[User:GeneralNotability/mark-locked.js]]
importScript('User:GeneralNotability/ip-ext-info.js'); // Backlink: [[User:GeneralNotability/ip-ext-info.js]]
importScript('User:Amorymeltzer/crathighlighter.js'); // Backlink: [[User:Amorymeltzer/crathighlighter.js]]
importScript('User:Mvolz/displayContributions.js'); // Backlink: [[User:Mvolz/displayContributions.js]]
window.highlight_order = ['arbcom', 'bureaucrat', 'checkuser','oversight', 'interface-admin', 'sysop', 'steward'];
importScript('User:Anomie/linkclassifier.js'); // Backlink: [[User:Anomie/linkclassifier.js]]
importScript('User:DannyS712/Pending_changes.js'); // Backlink: [[User:DannyS712/Pending_changes.js]]
importScript('User:SuperHamster/CiteUnseen.js'); // Backlink: [[User:SuperHamster/CiteUnseen.js]]
importScript('User:BrandonXLF/TodoList.js'); // [[User:BrandonXLF/TodoList.js]]
importScript('User:Pythoncoder/Scripts/voteSymbols.js'); // Backlink: [[User:Pythoncoder/Scripts/voteSymbols.js]]
window.markAdminCfg = {
groups: {
'abusefilter': { enabled: true },
'abusefilter-helper': { enabled: true },
'accountcreator': { enabled: true },
'autoreviewer': { enabled: true },
'extendedmover': { enabled: true },
'filemover': { enabled: true },
'massmessage-sender': { enabled: true },
'templateeditor': { enabled: true },
'vrt-permissions': { enabled: true },
'patroller': { enabled: true },
'reviewer': { enabled: true },
'rollbacker': { enabled: true },
}
};
importScript('User:GoldenRing/wordcount.js'); // Backlink: [[User:GoldenRing/wordcount.js]]
importScript('User:Andy_M._Wang/closeRM.js'); // Backlink: [[User:Andy_M._Wang/closeRM.js]]
importScript('User:RedWarn/.js'); // Backlink: [[User:RedWarn/.js]]
importScript('User:Firefly/more-block-info.js'); // Backlink: [[User:Firefly/more-block-info.js]]
importScript('User:Evad37/rater.js'); // Backlink: [[User:Evad37/rater.js]]
//importScript('User:10nm/beta.js'); // Backlink: [[User:10nm/beta.js]]
mw.loader.load('https://commons.wikimedia.org/w/index.php?title=User:Jack_who_built_the_house/convenientDiscussions.js&action=raw&ctype=text/javascript');
mw.hook('convenientDiscussions.commentsReady').add(function () {
importScript('User:Gary/comments in local time.js'); // Backlink: [[User:Gary/comments in local time.js]]
});
importScript('User:Suffusion of Yellow/effp-helper.js'); // Backlink: [[User:Suffusion of Yellow/effp-helper.js]]
importScript('User:DannyS712/SATG.js'); // Backlink: [[User:DannyS712/SATG.js]]
importScript('User:GeneralNotability/edit-filter-hit-analyzer.js'); // Backlink: [[User:GeneralNotability/edit-filter-hit-analyzer.js]]
importScript('User:DannyS712/DiscussionCloser.js'); // Backlink: [[User:DannyS712/DiscussionCloser.js]]
importScript('User:Shubinator/DYKcheck.js'); // Backlink: [[User:Shubinator/DYKcheck.js]]
importScript('User:Ohconfucius/script/MOSNUM dates.js'); // Backlink: [[User:Ohconfucius/script/MOSNUM dates.js]]
importScript('User:Writ Keeper/Scripts/massRollback.js'); // Backlink: [[User:Writ Keeper/Scripts/massRollback.js]]
importScript('User:Enterprisey/cv-revdel.js'); // Backlink: [[User:Enterprisey/cv-revdel.js]]
importScript( 'User:Novem Linguae/Scripts/CiteHighlighter.js' ); // Backlink: [[User:Novem Linguae/Scripts/CiteHighlighter.js]]
importScript('User:Enterprisey/orcp-helper.js'); // Backlink: [[User:Enterprisey/orcp-helper.js]]
importScript('User:Evad37/duplinks-alt.js'); // Backlink: [[User:Evad37/duplinks-alt.js]]
importScript('User:BrandonXLF/MoreDiffInfo.js'); // Backlink: [[User:BrandonXLF/MoreDiffInfo.js]]
importScript('User:Mdaniels5757/markAdmins.js'); // Backlink: [[User:Mdaniels5757/markAdmins.js]]
importScript('User:Plantaest/TestVue.js'); // Backlink: [[User:Plantaest/TestVue.js]]
importScript('User:Alexis Jazz/TakeAHikeMobileDiff.js'); // Backlink: [[User:Alexis Jazz/TakeAHikeMobileDiff.js]]
importScript('User:Kephir/gadgets/table-editor.js'); // Backlink: [[User:Kephir/gadgets/table-editor.js]]
importScript('User:TheresNoTime/linkThings.js'); // Backlink: [[User:TheresNoTime/linkThings.js]]
importScript('User:Lomrjyo/gPrefLink.js'); // Backlink: [[User:Lomrjyo/gPrefLink.js]]
importScript('User:Epicgenius/forceineditbox.js'); // Backlink: [[User:Epicgenius/forceineditbox.js]]
importScript('User:Epicgenius/safetyedit.js'); // Backlink: [[User:Epicgenius/safetyedit.js]]
importScript('User:SD0001/StubSorter.js'); // Backlink: [[User:SD0001/StubSorter.js]]
console.log(mw.config.get('wgHostname'));
console.log(mw.config.get('wgVersion'));
importScript('User:Alexis Jazz/Kill-It-With-Fire.js'); // Backlink: [[User:Alexis Jazz/Kill-It-With-Fire.js]]
importScript('User:Nux/CategorySortKeys.js'); // Backlink: [[User:Nux/CategorySortKeys.js]]
importScript('User:NightWolf1223/test.js'); // Backlink: [[User:NightWolf1223/test.js]]
importScript('user:Qwertyytrewqqwerty/DisamAssist.js'); // Backlink: [[user:Qwertyytrewqqwerty/DisamAssist.js]]
importScript('User:SD0001/W-Ping.js'); // Backlink: [[User:SD0001/W-Ping.js]]
importScript('User:Bradv/Scripts/Superlinks.js'); // Backlink: [[User:Bradv/Scripts/Superlinks.js]]
importScript('User:Trappist the monk/HarvErrors.js'); // Backlink: [[User:Trappist the monk/HarvErrors.js]]
importScript('User:Suffusion of Yellow/FilterDebugger.js'); // Backlink: [[User:Suffusion of Yellow/FilterDebugger.js]]
importScript('User:Ingenuity/AntiVandal.js'); // Backlink: [[User:Ingenuity/AntiVandal.js]]
importScript('User:Music1201/MyCSD.js'); // Backlink: [[User:Music1201/MyCSD.js]]
importScript('User:Terasail/COI Request Tool.js'); // Backlink: [[User:Terasail/COI Request Tool.js]]
importScript('User:Evad37/OneClickArchiver.js'); // Backlink: [[User:Evad37/OneClickArchiver.js]]
importScript('User:Lemonaka/WD.js'); // Backlink: [[User:Lemonaka/WD.js]]
importScript('User:Guywan/Scripts/ConfirmLogout.js'); // Backlink: [[User:Guywan/Scripts/ConfirmLogout.js]]
importScript('User:Novem Linguae/Scripts/anrfc-lister.js'); // Backlink: [[User:Novem Linguae/Scripts/anrfc-lister.js]]
importScript('User:Nardog/RefRenamer.js'); // Backlink: [[User:Nardog/RefRenamer.js]]
importScript('User:Eejit43/scripts/redirect-helper.js'); // Backlink: [[User:Eejit43/scripts/redirect-helper.js]]
importScript('User:Terasail/Edit_Request_Tool.js'); // Backlink: [[User:Terasail/Edit_Request_Tool.js]]
importScript('User:Lourdes/PageCuration.js'); // Backlink: [[User:Lourdes/PageCuration.js]]
importScript('User:PrimeHunter/Impact.js'); // Backlink: [[User:PrimeHunter/Impact.js]]
importScript('User:Enterprisey/AFCRHS.js'); // Backlink: [[User:Enterprisey/AFCRHS.js]]
importScript('User:Qwertyytrewqqwerty/DisamAssist.js'); // Backlink: [[User:Qwertyytrewqqwerty/DisamAssist.js]]
importScript('User:Lingzhi2/reviewsourcecheck-sb.js'); // Backlink: [[User:Lingzhi2/reviewsourcecheck-sb.js]]
importScript('User:Gary/nominations viewer.js'); // Backlink: [[User:Gary/nominations viewer.js]]
importScript('User:Theleekycauldron/DYK_promoter.js'); // Backlink: [[User:Theleekycauldron/DYK_promoter.js]]
importScript('User:DanCherek/UAABotRemover.js'); // Backlink: [[User:DanCherek/UAABotRemover.js]]
importScript('User:MPGuy2824/MoveToDraft.js'); // Backlink: [[User:MPGuy2824/MoveToDraft.js]]
importScript('User:Rublov/anonymize.js'); // Backlink: [[User:Rublov/anonymize.js]]
importScript('Wikipedia:AutoEd/complete.js'); // Backlink: [[Wikipedia:AutoEd/complete.js]]
importScript('User:Aaron_Liu/Watchlyst_Greybar_Unsin.js'); // Backlink: [[User:Aaron_Liu/Watchlyst_Greybar_Unsin.js]]
importScript('User:Novem_Linguae/Scripts/DontForgetG12.js'); // Backlink: [[User:Novem_Linguae/Scripts/DontForgetG12.js]]
importScript('User:BrandonXLF/HotDefaultSort.js'); // Backlink: [[User:BrandonXLF/HotDefaultSort.js]]
importScript('User:Enterprisey/section-redir-note.js'); // Backlink: [[User:Enterprisey/section-redir-note.js]]
importScript('User:Nardog/SmartDiff.js'); // Backlink: [[User:Nardog/SmartDiff.js]]
importScript('User:Novem Linguae/Scripts/DraftCleaner.js'); // Backlink: [[User:Novem Linguae/Scripts/DraftCleaner.js]]
importScript('User:Novem Linguae/Scripts/ShowAdminMessages.js'); // Backlink: [[User:Novem Linguae/Scripts/ShowAdminMessages.js]]
importScript('User:Ahecht/Scripts/TemplateSearch.js'); // Backlink: [[User:Ahecht/Scripts/TemplateSearch.js]]
importScript('User:DannyS712/SectionRemover.js'); // Backlink: [[User:DannyS712/SectionRemover.js]]
importScript('User:TheresNoTime/Scripts/CT-Helper.js'); // Backlink: [[User:TheresNoTime/Scripts/CT-Helper.js]]
importScript('User:DannyS712/deOrphan.js'); // Backlink: [[User:DannyS712/deOrphan.js]]
$( document ).ready( function() {
mw.util.addPortletLink(
'p-personal',
mw.util.getUrl( 'Special:MyPage/common.js' ),
'common.js',
'l-csd',
'View personal common.js',
null,
'#pt-preferences'
);
});
importScript('User:Nardog/Unpipe.js'); // Backlink: [[User:Nardog/Unpipe.js]]
importScript('User:Nardog/CatChangesViewer.js'); // Backlink: [[User:Nardog/CatChangesViewer.js]]
mw.loader.load('/w/index.php?title=User:Lupin/recent2.js&action=raw&ctype=text/javascript'); // [[User:Lupin/recent2.js]]
importScript('User:Þjarkur/CleanDiffURLs.js'); // Backlink: [[User:Þjarkur/CleanDiffURLs.js]]
importScript('User:BilledMammal/rmCloserExpanded.js'); // Backlink: [[User:BilledMammal/rmCloserExpanded.js]]
importScript('User:Novem_Linguae/Scripts/GANReviewTool.js'); // Backlink: [[User:Novem_Linguae/Scripts/GANReviewTool.js]]
importScript('User:Elli/OneClickArchiver.js'); // Backlink: [[User:Elli/OneClickArchiver.js]]