dotfiles

Configuration for the software I use.
git clone https://git.sr.ht/~jbauer/dotfiles
Log | Files | Refs | README | LICENSE

commit 5241b892af27c0819a19e53dbeed91a899835439
parent 53cff695d6aadce71a304659b73906a6856db6c3
Author: Jake Bauer <jbauer@paritybit.ca>
Date:   Tue, 27 Oct 2020 05:37:51 -0400

Add qutebrowser config

Diffstat:
A.config/qutebrowser/autoconfig.yml | 10++++++++++
A.config/qutebrowser/config.py | 243+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 253 insertions(+), 0 deletions(-)

diff --git a/.config/qutebrowser/autoconfig.yml b/.config/qutebrowser/autoconfig.yml @@ -0,0 +1,10 @@ +# If a config.py file exists, this file is ignored unless it's explicitly loaded +# via config.load_autoconfig(). For more information, see: +# https://github.com/qutebrowser/qutebrowser/blob/master/doc/help/configuring.asciidoc#loading-autoconfigyml +# DO NOT edit this file by hand, qutebrowser will overwrite it. +# Instead, create a config.py - see :help for details. + +config_version: 2 +settings: + fonts.completion.entry: + global: 20px "DejaVu Sans Mono" diff --git a/.config/qutebrowser/config.py b/.config/qutebrowser/config.py @@ -0,0 +1,243 @@ +# Autogenerated config.py +# +# NOTE: config.py is intended for advanced users who are comfortable +# with manually migrating the config file on qutebrowser upgrades. If +# you prefer, you can also configure qutebrowser using the +# :set/:bind/:config-* commands without having to write a config.py +# file. +# +# Documentation: +# qute://help/configuring.html +# qute://help/settings.html + +# Uncomment this to still load settings configured via autoconfig.yml +# config.load_autoconfig() + +# Which cookies to accept. With QtWebEngine, this setting also controls +# other features with tracking capabilities similar to those of cookies; +# including IndexedDB, DOM storage, filesystem API, service workers, and +# AppCache. Note that with QtWebKit, only `all` and `never` are +# supported as per-domain values. Setting `no-3rdparty` or `no- +# unknown-3rdparty` per-domain on QtWebKit will have the same effect as +# `all`. If this setting is used with URL patterns, the pattern gets +# applied to the origin/first party URL of the page making the request, +# not the request URL. +# Type: String +# Valid values: +# - all: Accept all cookies. +# - no-3rdparty: Accept cookies from the same origin only. This is known to break some sites, such as GMail. +# - no-unknown-3rdparty: Accept cookies from the same origin only, unless a cookie is already set for the domain. On QtWebEngine, this is the same as no-3rdparty. +# - never: Don't accept cookies at all. +config.set('content.cookies.accept', 'all', 'chrome-devtools://*') + +# Which cookies to accept. With QtWebEngine, this setting also controls +# other features with tracking capabilities similar to those of cookies; +# including IndexedDB, DOM storage, filesystem API, service workers, and +# AppCache. Note that with QtWebKit, only `all` and `never` are +# supported as per-domain values. Setting `no-3rdparty` or `no- +# unknown-3rdparty` per-domain on QtWebKit will have the same effect as +# `all`. If this setting is used with URL patterns, the pattern gets +# applied to the origin/first party URL of the page making the request, +# not the request URL. +# Type: String +# Valid values: +# - all: Accept all cookies. +# - no-3rdparty: Accept cookies from the same origin only. This is known to break some sites, such as GMail. +# - no-unknown-3rdparty: Accept cookies from the same origin only, unless a cookie is already set for the domain. On QtWebEngine, this is the same as no-3rdparty. +# - never: Don't accept cookies at all. +config.set('content.cookies.accept', 'all', 'devtools://*') + +# User agent to send. The following placeholders are defined: * +# `{os_info}`: Something like "X11; Linux x86_64". * `{webkit_version}`: +# The underlying WebKit version (set to a fixed value with +# QtWebEngine). * `{qt_key}`: "Qt" for QtWebKit, "QtWebEngine" for +# QtWebEngine. * `{qt_version}`: The underlying Qt version. * +# `{upstream_browser_key}`: "Version" for QtWebKit, "Chrome" for +# QtWebEngine. * `{upstream_browser_version}`: The corresponding +# Safari/Chrome version. * `{qutebrowser_version}`: The currently +# running qutebrowser version. The default value is equal to the +# unchanged user agent of QtWebKit/QtWebEngine. Note that the value +# read from JavaScript is always the global value. With QtWebEngine +# between 5.12 and 5.14 (inclusive), changing the value exposed to +# JavaScript requires a restart. +# Type: FormatString +config.set('content.headers.user_agent', 'Mozilla/5.0 ({os_info}) AppleWebKit/{webkit_version} (KHTML, like Gecko) {upstream_browser_key}/{upstream_browser_version} Safari/{webkit_version}', 'https://web.whatsapp.com/') + +# User agent to send. The following placeholders are defined: * +# `{os_info}`: Something like "X11; Linux x86_64". * `{webkit_version}`: +# The underlying WebKit version (set to a fixed value with +# QtWebEngine). * `{qt_key}`: "Qt" for QtWebKit, "QtWebEngine" for +# QtWebEngine. * `{qt_version}`: The underlying Qt version. * +# `{upstream_browser_key}`: "Version" for QtWebKit, "Chrome" for +# QtWebEngine. * `{upstream_browser_version}`: The corresponding +# Safari/Chrome version. * `{qutebrowser_version}`: The currently +# running qutebrowser version. The default value is equal to the +# unchanged user agent of QtWebKit/QtWebEngine. Note that the value +# read from JavaScript is always the global value. With QtWebEngine +# between 5.12 and 5.14 (inclusive), changing the value exposed to +# JavaScript requires a restart. +# Type: FormatString +config.set('content.headers.user_agent', 'Mozilla/5.0 ({os_info}) AppleWebKit/{webkit_version} (KHTML, like Gecko) {upstream_browser_key}/{upstream_browser_version} Safari/{webkit_version} Edg/{upstream_browser_version}', 'https://accounts.google.com/*') + +# User agent to send. The following placeholders are defined: * +# `{os_info}`: Something like "X11; Linux x86_64". * `{webkit_version}`: +# The underlying WebKit version (set to a fixed value with +# QtWebEngine). * `{qt_key}`: "Qt" for QtWebKit, "QtWebEngine" for +# QtWebEngine. * `{qt_version}`: The underlying Qt version. * +# `{upstream_browser_key}`: "Version" for QtWebKit, "Chrome" for +# QtWebEngine. * `{upstream_browser_version}`: The corresponding +# Safari/Chrome version. * `{qutebrowser_version}`: The currently +# running qutebrowser version. The default value is equal to the +# unchanged user agent of QtWebKit/QtWebEngine. Note that the value +# read from JavaScript is always the global value. With QtWebEngine +# between 5.12 and 5.14 (inclusive), changing the value exposed to +# JavaScript requires a restart. +# Type: FormatString +config.set('content.headers.user_agent', 'Mozilla/5.0 ({os_info}) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99 Safari/537.36', 'https://*.slack.com/*') + +# Load images automatically in web pages. +# Type: Bool +config.set('content.images', True, 'chrome-devtools://*') + +# Load images automatically in web pages. +# Type: Bool +config.set('content.images', True, 'devtools://*') + +# Enable JavaScript. +# Type: Bool +config.set('content.javascript.enabled', True, 'chrome-devtools://*') + +# Enable JavaScript. +# Type: Bool +config.set('content.javascript.enabled', True, 'devtools://*') + +# Enable JavaScript. +# Type: Bool +config.set('content.javascript.enabled', True, 'chrome://*/*') + +# Enable JavaScript. +# Type: Bool +config.set('content.javascript.enabled', True, 'qute://*/*') + +# Allow websites to show notifications. +# Type: BoolAsk +# Valid values: +# - true +# - false +# - ask +config.set('content.notifications', True, 'https://pleroma.paritybit.ca') + +# Directory to save downloads to. If unset, a sensible OS-specific +# default is used. +# Type: Directory +c.downloads.location.directory = '/home/jbauer/temp' + +# Start page +c.url.start_pages = ["https://www.paritybit.ca"] + +# Appearance +c.tabs.show = 'always' +# Text color of the completion widget. May be a single color to use for +# all columns or a list of three colors, one for each column. +c.colors.completion.fg = ['#91acd1', 'white', 'white'] +# Background color of the completion widget for odd rows. +c.colors.completion.odd.bg = '#161821' +# Background color of the completion widget for even rows. +c.colors.completion.even.bg = '#252835' +# Foreground color of completion widget category headers. +c.colors.completion.category.fg = '#a093c7' +# Background color of the completion widget category headers. +c.colors.completion.category.bg = '#161821' +# Top border color of the completion widget category headers. +c.colors.completion.category.border.top = '#c6c8d1' +# Bottom border color of the completion widget category headers. +c.colors.completion.category.border.bottom = '#c6c8d1' +# Foreground color of the selected completion item. +c.colors.completion.item.selected.fg = '#d2d4de' +# Background color of the selected completion item. +c.colors.completion.item.selected.bg = '#91674a' +# Foreground color of the matched text in the selected completion item. +c.colors.completion.item.selected.match.fg = '#a093c7' +# Foreground color of the matched text in the completion. +c.colors.completion.match.fg = '#a093c7' +# Color of the scrollbar handle in the completion view. +c.colors.completion.scrollbar.fg = '#d2d4de' +# Background color for the download bar. +c.colors.downloads.bar.bg = '#161821' +# Background color for downloads with errors. +c.colors.downloads.error.bg = '#e27878' +# Font color for hints. +c.colors.hints.fg = '#161821' +# Font color for the matched part of hints. +c.colors.hints.match.fg = '#d2d4de' +# Background color of an info message. +c.colors.messages.info.bg = '#161821' +# Background color of the statusbar. +c.colors.statusbar.normal.bg = '#161821' +# Foreground color of the statusbar in insert mode. +c.colors.statusbar.insert.fg = '#d2d4de' +# Background color of the statusbar in insert mode. +c.colors.statusbar.insert.bg = '#161821' +# Background color of the statusbar in passthrough mode. +c.colors.statusbar.passthrough.bg = '#84a0c6' +# Background color of the statusbar in command mode. +c.colors.statusbar.command.bg = '#161821' +# Foreground color of the URL in the statusbar when there's a warning. +c.colors.statusbar.url.warn.fg = '#e9b189' +# Background color of the tab bar. +c.colors.tabs.bar.bg = '#1c1f34' +# Background color of unselected odd tabs. +c.colors.tabs.odd.bg = '#161821' +# Background color of unselected even tabs. +c.colors.tabs.even.bg = '#161821' +# Background color of selected odd tabs. +c.colors.tabs.selected.odd.bg = '#161821' +# Background color of selected even tabs. +c.colors.tabs.selected.even.bg = '#161821' +# Background color of pinned unselected odd tabs. +c.colors.tabs.pinned.odd.bg = 'seagreen' +# Background color of pinned unselected even tabs. +c.colors.tabs.pinned.even.bg = 'darkseagreen' +# Background color of pinned selected odd tabs. +c.colors.tabs.pinned.selected.odd.bg = '#161821' +# Background color of pinned selected even tabs. +c.colors.tabs.pinned.selected.even.bg = '#161821' + +# Default font families to use. Whenever "default_family" is used in a +# font setting, it's replaced with the fonts listed here. If set to an +# empty value, a system-specific monospace default is used. +# Type: List of Font, or Font +c.fonts.default_family = '"DejaVu Sans Mono"' +c.fonts.web.family.standard = '"DejaVu Sans"' +c.fonts.web.family.sans_serif = '"DejaVu Sans"' +c.fonts.web.family.serif = '"DejaVu Serif"' +c.fonts.web.family.fixed = '"DejaVu Sans Mono"' +c.fonts.web.size.default = 20 +c.fonts.web.size.default_fixed = 16 + +# Default font size to use. Whenever "default_size" is used in a font +# setting, it's replaced with the size listed here. Valid values are +# either a float value with a "pt" suffix, or an integer value with a +# "px" suffix. +# Type: String +c.fonts.default_size = '20px' + +# Font used in the completion widget. +c.fonts.completion.entry = '20px "DejaVu Sans Mono"' +# Font used for the debugging console. +c.fonts.debug_console = '20px "DejaVu Sans Mono"' +# Font used for prompts. +c.fonts.prompts = 'default_size sans-serif' +# Font used in the statusbar. +c.fonts.statusbar = '20px "DejaVu Sans Mono"' +# Font used in context menu +c.fonts.contextmenu = '20px "DejaVu Sans Mono"' + +# Bindings for normal mode +config.bind('M', 'hint links spawn mpv {hint-url}') +config.bind('m', 'spawn mpv {url}') +config.bind('Z', 'hint links spawn st -e youtube-dl {hint-url}') +config.bind('t', 'set-cmd-text -s :open -t') +config.bind('xb', 'config-cycle statusbar.show always never') +config.bind('xt', 'config-cycle tabs.show always never') +config.bind('xx', 'config-cycle statusbar.show always never;; config-cycle tabs.show always never')