mirror of
https://github.com/kovidgoyal/kitty.git
synced 2024-11-11 01:28:19 +03:00
Nicer error message for zsh versions before 5.1
This commit is contained in:
parent
d6492264c7
commit
31dfee8a95
@ -27,6 +27,11 @@ fi
|
||||
[[ ! -r "$_ksi_file" ]] || 'builtin' 'source' '--' "$_ksi_file"
|
||||
} always {
|
||||
if [[ -o 'interactive' && -n "${KITTY_SHELL_INTEGRATION-}" ]]; then
|
||||
'builtin' 'autoload' '--' 'is-at-least'
|
||||
'is-at-least' "5.1" || {
|
||||
builtin echo "ZSH ${ZSH_VERSION} is too old for kitty shell integration" > /dev/stderr
|
||||
return
|
||||
}
|
||||
# ${(%):-%x} is the path to the current file.
|
||||
# On top of it we add :A:h to get the directory.
|
||||
'builtin' 'typeset' _ksi_file="${${(%):-%x}:A:h}"/kitty-integration
|
||||
|
Loading…
Reference in New Issue
Block a user