configuration/config/qutebrowser/config.py

79 lines
3.0 KiB
Python
Raw Normal View History

2017-09-18 10:17:48 +02:00
#!/usr/bin/python
2017-09-26 09:59:27 +02:00
config.backend = "webengine"
2017-09-18 10:17:48 +02:00
config.load_autoconfig = False
# c.qt.force_software_rendering = "software-opengl"
2017-09-18 10:17:48 +02:00
c.completion.shrink = True
c.confirm_quit = ["downloads"]
# c.content.developer_extras = True
c.content.proxy = "socks://localhost:9050"
c.content.javascript.enabled = False
2017-09-18 10:17:48 +02:00
c.content.ssl_strict = True
c.content.headers.accept_language = "en-US,en;q=0.5"
c.content.headers.custom = { "accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8" }
c.content.headers.user_agent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36"
2018-11-30 10:03:30 +01:00
c.content.webrtc_ip_handling_policy = "default-public-interface-only"
c.content.cookies.accept = "no-3rdparty"
2017-09-18 10:17:48 +02:00
c.downloads.location.directory = "/data/temporary"
c.downloads.location.suggestion = "both"
c.downloads.open_dispatcher = "rifle"
c.editor.command = ["st", "-e", "vis", "{}"]
2017-09-18 10:17:48 +02:00
c.hints.auto_follow = "full-match"
c.hints.dictionary = "/usr/share/dict/mnemonic"
c.hints.mode = "word"
c.new_instance_open_target = "tab-silent"
2018-01-04 17:46:18 +01:00
c.session.default_name = "default"
2017-09-18 10:17:48 +02:00
c.tabs.background = True
c.tabs.last_close = "close"
c.tabs.show = "multiple"
c.url.default_page = "about:blank"
c.url.start_pages = ["qute://bookmarks"]
2017-10-02 23:48:56 +02:00
c.aliases = { "wq": "quit --save"
, "set": "set -t"
, "bind": "bind -t"
2017-11-06 17:23:19 +01:00
, "quickmarks": "open qute://bookmarks/"
2017-10-02 23:48:56 +02:00
}
2017-09-18 10:17:48 +02:00
config.bind("<backspace>", "back", mode="normal")
config.bind("x", "spawn --detach mpv {url}", mode="normal")
config.bind(";x", "hint links spawn --detach mpv {hint-url}", mode="normal")
2018-01-04 17:46:18 +01:00
config.bind("si", "jseval --quiet --file simplyread.js", mode="normal")
config.bind("<Alt+j>", "prompt-item-focus next", mode="prompt")
config.bind("<Alt+k>", "prompt-item-focus prev", mode="prompt")
config.bind("<Alt+l>", "fake-key -g /", mode="prompt")
config.bind("<Alt+h>", "rl-unix-filename-rubout", mode="prompt")
2017-11-06 17:23:19 +01:00
# I don't use bookmarks
config.unbind('wB')
config.unbind('gb')
config.unbind('gB')
config.unbind('Sb')
2018-03-12 10:36:09 +01:00
# Allowing javascript for...
2018-07-02 16:47:27 +02:00
allowed = [ 'https://duckduckgo.com/*'
, 'https://calendar.google.com/*'
2018-03-12 10:36:09 +01:00
, 'https://www.facebook.com/*'
, 'https://www.glowing-bear.org/*'
, 'https://github.com/*'
2018-03-25 14:00:16 +02:00
, 'https://*.ugent.be/*'
2018-03-12 10:36:09 +01:00
, 'https://secure.ogone.com/*' # bancontact
, 'https://belgium-3dsecure.wlp-acs.com/*' # bancontact
, 'https://bcr.girogate.be/*' # bancontact
2018-03-25 14:00:16 +02:00
, 'https://*.axabank.be/*'
, 'https://*.triodos.be/*'
, 'https://*.ing.be/*'
, 'https://accounts.google.com/*'
, 'https://www.openstreetmap.org/*'
, 'https://web.whatsapp.com'
, 'https://chat.zeus.gent/*'
, 'https://mattermost.zeus.gent/*'
, 'https://posteo.de/*'
, 'https://doc.rust-lang.org/*'
2018-11-21 16:37:36 +01:00
, 'https://www.paypal.com/*'
2018-03-12 10:36:09 +01:00
]
for pattern in allowed:
config.set('content.javascript.enabled', True, pattern)