Browse Source

[zshrc] Add support for Kitty term emulator

merge-requests/1/merge
lhark 7 years ago
parent
commit
e0dc869471
  1. 5
      functions
  2. 30
      zshrc

5
functions

@ -89,4 +89,9 @@ ymsearch() {
mpv --ytdl-format=bestaudio ytdl://ytsearch:"$(xsel -ob)"
}
# Kitty terminfo setup for ssh
ssh_kitty () {
kitty +kitten ssh "$@"
}
# vim: ft=zsh

30
zshrc

@ -51,6 +51,12 @@ colors
# Term specific hacks
case $TERM in
*kitty)
preexec () {
print -n "\e]0;kitty - $1 - ${HOST} - ${PWD}\a"
}
alias ssh='ssh_kitty'
;;
xterm*)
preexec () {
print -n "\e]0;xterm - $1 - ${HOST} - ${PWD}\a"
@ -100,6 +106,17 @@ HISTFILE=~/.history
HISTTIMEFORMAT="%d/%m %H:%M:%S "
######################
# Load ZSH functions #
######################
zmodload zsh/complist
autoload -U compinit promptinit
compinit
colors
autoload -U zsh-mime-setup
######################
# Completion options #
######################
@ -138,17 +155,8 @@ zstyle ':completion:*:manuals' separate-sections true
# comme la recherche d'un paquet aptitude install moz<tab>
zstyle ':completion:*' use-cache on
zstyle ':completion:*' cache-path ~/.zs
######################
# Load ZSH functions #
######################
zmodload zsh/complist
autoload -U compinit promptinit
compinit
colors
autoload -U zsh-mime-setup
# Enable ssh completion for kitty ssh
compdef ssh_kitty=ssh
################

Loading…
Cancel
Save