aboutsummaryrefslogtreecommitdiff
path: root/internal/wizard.zsh
diff options
context:
space:
mode:
authorromkatv <roman.perepelitsa@gmail.com>2020-03-06 13:40:59 +0300
committerromkatv <roman.perepelitsa@gmail.com>2020-03-06 13:40:59 +0300
commit6ccf26ff8e3f03d88a23ec5aec6da33ab33d6d4b (patch)
tree27ebfc3955d3030e040cd3162219a2466cc9e74f /internal/wizard.zsh
parenta2af168eb4099cd2f19fcb671ef6b5d55f5bc7f9 (diff)
don't use href when the terminal is known to print garbage on it
Diffstat (limited to 'internal/wizard.zsh')
-rwxr-xr-xinternal/wizard.zsh6
1 files changed, 5 insertions, 1 deletions
diff --git a/internal/wizard.zsh b/internal/wizard.zsh
index 4d91f95c..5a9dc242 100755
--- a/internal/wizard.zsh
+++ b/internal/wizard.zsh
@@ -153,7 +153,11 @@ function print_prompt() {
function href() {
local url=${${1//\%/%%}//\\/\\\\}
- print -r -- '%{\e]8;;'$url'\e\\%}'$url'%{\e]8;;\e\\%}'
+ if (( _p9k_term_has_href )); then
+ print -r -- '%{\e]8;;'$url'\e\\%}'$url'%{\e]8;;\e\\%}'
+ else
+ print -r -- $url
+ fi
}
function flowing() {