Add shell integration

This commit is contained in:
rydesun 2022-01-05 13:05:58 +08:00
parent 4e13c18575
commit c5ec8d43df
2 changed files with 11 additions and 0 deletions

View file

@ -21,3 +21,6 @@ map ctrl+g>ctrl+i kitten hints --type=ip --program -
map ctrl+g>shift+i kitten hints --type=ip --program @
map ctrl+g>ctrl+n kitten hints --type=linenum nvim +{line} {path}
map ctrl+g>ctrl+y kitten hints --type=hyperlink
# 在zsh中手动集成
shell_integration disabled

View file

@ -60,6 +60,14 @@ autoload -Uz colors && colors
source ${ZDOTDIR}/theme
((_ENV_MODERN_UI)) && _theme_use_icon || _theme_use_text
# 与kitty集成
if [[ -n "$KITTY_INSTALLATION_DIR" ]]; then
export KITTY_SHELL_INTEGRATION=enabled
autoload -Uz "$KITTY_INSTALLATION_DIR"/shell-integration/zsh/kitty-integration
kitty-integration
unfunction kitty-integration
fi
# 其他
fpath+=(${ZDOTDIR}/functions ${ZDOTDIR}/Completion)
# function: 模仿fish折叠路径