From b100aa0dded5583a87a19d528ed722b37a8901c2 Mon Sep 17 00:00:00 2001 From: Von Random Date: Thu, 15 Nov 2018 12:44:56 +0300 Subject: [PATCH] some features to aliases, some cosmetic shit --- tmux.conf | 3 ++- zshrc | 28 ++++++++++++++-------------- 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/tmux.conf b/tmux.conf index e1a4217..7370442 100644 --- a/tmux.conf +++ b/tmux.conf @@ -7,7 +7,7 @@ bind h select-pane -L bind j select-pane -D bind k select-pane -U bind l select-pane -R -bind r switch-client -T resize +bind r display "resize" \; switch-client -T resize bind -T resize -r h resize-pane -L 5 bind -T resize -r j resize-pane -D 5 bind -T resize -r k resize-pane -U 5 @@ -18,6 +18,7 @@ bind y command-prompt break-pane bind -n M-w next-window bind -n M-q previous-window bind -n M-` last-window +set -g terminal-overrides 'rxvt-unicode*:sitm@,ritm@' set -g prefix C-g set -g update-environment "DISPLAY SSH_ASKPASS SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY" set -g mode-keys "vi" diff --git a/zshrc b/zshrc index 7dfefcc..da63fa5 100644 --- a/zshrc +++ b/zshrc @@ -168,15 +168,23 @@ alias atmux='command tmux -2 attach' # screen alias rscreen='command screen -Dr' alias scr='command screen sudo -Es' + +# (neo)vim +vimcmd=$(whence nvim) || vimcmd=$(whence vim) || vimcmd=$(whence vi) +alias vim=$vimcmd +alias vi='vim' + +# termcompat +if [[ -x $(whence termcompat) ]]; then + alias s='command termcompat ssh' +else + alias s='command ssh' +fi + # }}} # {{{ plugins -# vi alias -vim() { - vimcmd=$(whence nvim) || vimcmd=$(whence vim) || vimcmd=$(whence vi) - $vimcmd "$@" -} # grc -if [[ -x "$(whence grc)" ]]; then +if [[ -x $(whence grc) ]]; then cmds=(\ cc configure cvs df dig gcc gmake id ip last lsof make mount \ mtr netstat ping ping6 ps tcpdump traceroute traceroute6 \ @@ -203,12 +211,4 @@ greset() { /usr/bin/git clean -fd /usr/bin/git reset --hard } -# more compatible TERM for ssh sessions -s() { - if termcompat=$(whence termcompat); then - $termcompat ssh "$@" - else - ssh "$@" - fi -} # }}}