Last active
February 10, 2023 19:43
-
-
Save wheresalice/e43560139b8a6f67bf23ca59a02ace41 to your computer and use it in GitHub Desktop.
Redirect Imgur links to rimgo to avoid endless hate scrolling. Working version as of January 2023
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
/* | |
DESCRIPTION: This is a file that after installing a greasemonkey | |
extension can be used to convert imgur to any rimgo instance. | |
NOTE: I might change this really often because instances may fail. | |
---- | |
Copyright (C) 2021 Zortazert and other contributors | |
This program is free software: you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by | |
the Free Software Foundation, either version 3 of the License, or (at | |
your option) any later version. | |
This program is distributed in the hope that it will be useful, but | |
WITHOUT ANY WARRANTY; without even the implied warranty of | |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
General Public License for more details. | |
You should have received a copy of the GNU General Public License | |
along with this program. If not, see <https://www.gnu.org/licenses/>. | |
*/ | |
// ==UserScript== | |
// @name imgur to rimgo | |
// @version 1.0.1 | |
// @namespace Zera's userscripts | |
// @match http://imgur.com/* | |
// @match https://imgur.com/* | |
// @match http://i.imgur.com/* | |
// @match https://i.imgur.com/* | |
// @match http://www.imgur.com/* | |
// @match https://www.imgur.com/* | |
// @match https://imgur.io/* | |
// @grant none | |
// @run-at document-start | |
// ==/UserScript== | |
url = location.href | |
url = url.replace(/\bwww\.\b/, "") | |
if (url.includes("i.imgur.com")){ | |
url = url.replace("i.imgur.com","rimgo.bus-hit.me") | |
location.href = url | |
} | |
else{ | |
url = url.replace("imgur.com","rimgo.bus-hit.me") | |
url = url.replace("imgur.io", "rimgo.bus-hit.me") | |
location.href = url | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment