diff --git a/doc/help/settings.asciidoc b/doc/help/settings.asciidoc index eebdc5072..a9e7becd2 100644 --- a/doc/help/settings.asciidoc +++ b/doc/help/settings.asciidoc @@ -582,8 +582,14 @@ Default: * +pass:[sk]+: +pass:[set-cmd-text -s :bind]+ * +pass:[sl]+: +pass:[set-cmd-text -s :set -t]+ * +pass:[ss]+: +pass:[set-cmd-text -s :set]+ +* +pass:[tSH]+: +pass:[config-cycle -p -u *://*.{url:host}/* content.javascript.enabled ;; reload]+ +* +pass:[tSh]+: +pass:[config-cycle -p -u *://{url:host}/* content.javascript.enabled ;; reload]+ +* +pass:[tSu]+: +pass:[config-cycle -p -u {url} content.javascript.enabled ;; reload]+ * +pass:[th]+: +pass:[back -t]+ * +pass:[tl]+: +pass:[forward -t]+ +* +pass:[tsH]+: +pass:[config-cycle -p -t -u *://*.{url:host}/* content.javascript.enabled ;; reload]+ +* +pass:[tsh]+: +pass:[config-cycle -p -t -u *://{url:host}/* content.javascript.enabled ;; reload]+ +* +pass:[tsu]+: +pass:[config-cycle -p -t -u {url} content.javascript.enabled ;; reload]+ * +pass:[u]+: +pass:[undo]+ * +pass:[v]+: +pass:[enter-mode caret]+ * +pass:[wB]+: +pass:[set-cmd-text -s :bookmark-load -w]+ diff --git a/qutebrowser/commands/runners.py b/qutebrowser/commands/runners.py index 16c790eca..0932a8b89 100644 --- a/qutebrowser/commands/runners.py +++ b/qutebrowser/commands/runners.py @@ -63,6 +63,7 @@ def replace_variables(win_id, arglist): QUrl.FullyEncoded | QUrl.RemovePassword), 'url:pretty': lambda: _current_url(tabbed_browser).toString( QUrl.DecodeReserved | QUrl.RemovePassword), + 'url:host': lambda: _current_url(tabbed_browser).host(), 'clipboard': utils.get_clipboard, 'primary': lambda: utils.get_clipboard(selection=True), } diff --git a/qutebrowser/config/configdata.yml b/qutebrowser/config/configdata.yml index 2228bc1b4..d23682db8 100644 --- a/qutebrowser/config/configdata.yml +++ b/qutebrowser/config/configdata.yml @@ -2329,6 +2329,12 @@ bindings.default: : tab-pin q: record-macro "@": run-macro + tsh: config-cycle -p -t -u *://{url:host}/* content.javascript.enabled ;; reload + tSh: config-cycle -p -u *://{url:host}/* content.javascript.enabled ;; reload + tsH: config-cycle -p -t -u *://*.{url:host}/* content.javascript.enabled ;; reload + tSH: config-cycle -p -u *://*.{url:host}/* content.javascript.enabled ;; reload + tsu: config-cycle -p -t -u {url} content.javascript.enabled ;; reload + tSu: config-cycle -p -u {url} content.javascript.enabled ;; reload insert: : open-editor : insert-text {primary}