Last active
August 29, 2015 13:56
-
-
Save Manishearth/9191984 to your computer and use it in GitHub Desktop.
Main site links on SE Meta topbar
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Main site link on meta topbar | |
// @namespace Manishearth | |
// @description Brings back the bold reputation counter/post scores! | |
// @include http://meta.stackoverflow.com/* | |
// @include http://meta.serverfault.com/* | |
// @include http://meta.superuser.com/* | |
// @include http://stackapps.com/* | |
// @include http://meta.*.stackexchange.com/* | |
// @include http://meta.askubuntu.com/* | |
// @include http://meta.mathoverflow.net/* | |
// @include http://discuss.area51.stackexchange.com/proposals/* | |
// @author Manish Goregaokar | |
// ==/UserScript== | |
function with_jquery(f) { | |
var script = document.createElement("script"); | |
script.type = "text/javascript"; | |
script.textContent = "(" + f.toString() + ")(jQuery)"; | |
document.body.appendChild(script); | |
}; | |
with_jquery(function ($) { | |
$('<a>main</a>').attr('href',document.location.origin.replace(/(meta\.|discuss\.)/,"")).insertBefore('.js-help-button') | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment