## Remove it to not load settings done via the GUI.
config.load_autoconfig()
+try:
+ from qutebrowser.api import interceptor, message
+ from PyQt5.QtCore import QUrl
+
+ def intercept(info: interceptor.Request):
+ url = info.request_url
+ if url.host() == "twitter.com":
+ url.setHost("nitter.net")
+ message.info("Redirecting to " + url.toString())
+ info.redirect(url)
+ if url.host() == "xkcd.com":
+ url.setHost("m.xkcd.com")
+ message.info("Redirecting to " + url.toString())
+ info.redirect(url)
+ if url.host() == "www.bristolpost.co.uk":
+ url.setUrl("https://outline.com/" + url.toString())
+ message.info("Redirecting to " + url.toString())
+ info.redirect(url)
+
+ interceptor.register(intercept)
+except ImportError:
+ pass
+
## Aliases for commands. The keys of the given dictionary are the
## aliases, while the values are the commands they map to.
## Type: Dict