~pvsr/dotfiles

06c21dc469bc3db267611950125cf7185ad94df6 — Peter Rice 1 year, 2 days ago c89f867
enable js by default
2 files changed, 14 insertions(+), 14 deletions(-)

M qutebrowser/.config/qutebrowser/conf.d/js.py
M qutebrowser/.config/qutebrowser/config.py
M qutebrowser/.config/qutebrowser/conf.d/js.py => qutebrowser/.config/qutebrowser/conf.d/js.py +13 -13
@@ 1,14 1,14 @@
#vim:ft=py
for protocol in (
        'file',
        'chrome',
        'qute'
        ):
    config.set('content.javascript.enabled', True, protocol + '://*')
if not config.get('content.javascript.enabled'):
    for protocol in (
            'file',
            'chrome',
            'qute'
            ):
        config.set('content.javascript.enabled', True, protocol + '://*')

try:
    with open(config.configdir / 'conf.d' / 'domains', 'r') as f:
        for domain in f.read().splitlines():
            config.set('content.javascript.enabled', True, domain)
except FileNotFoundError:
    config.set('content.javascript.enabled', True)
    try:
        with open(config.configdir / 'conf.d' / 'domains', 'r') as f:
            for domain in f.read().splitlines():
                config.set('content.javascript.enabled', True, domain)
    except FileNotFoundError:
        config.set('content.javascript.enabled', True)

M qutebrowser/.config/qutebrowser/config.py => qutebrowser/.config/qutebrowser/config.py +1 -1
@@ 31,7 31,7 @@ c.editor.command = ['termite', '-e', 'bash -c \'exec nvim -f {file} -c "normal {
c.auto_save.session = True

c.content.host_blocking.lists = ['https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts']
c.content.javascript.enabled = False
c.content.javascript.enabled = True
c.content.autoplay = False
c.content.pdfjs = True
c.content.netrc_file = '~/.netrc'