Commit 3f8878ae9227e75114086be34d62c484b10d6f3a Parent: 752290a196ccb011469fd144e72d843c6686662a Author: mcol <mcol@posteo.net> Date: 2019-04-05 08:58:54 +0100 Committer: mcol <mcol@posteo.net> Committed: 2019-04-05 08:58:54 +0100 tmux titles, removed old code from tmux.conf
vimrc Modified
@@ -19,17 +19,19 @@ call vundle#begin() Plugin 'VundleVim/Vundle.vim' " required + if hostname() == "zenbook" Plugin 'vimwiki/vimwiki' " vimwiki Plugin 'mcolligan/vimlab' " vimlab endif + if hostname() == "ardbeg" Plugin 'mcolligan/vimlab' " vimlab endif + Plugin 'junegunn/goyo.vim' Plugin 'mcolligan/vim-misc' " my vimrc and misc functions Plugin 'mcolligan/tide' " tmux ide -"Plugin 'christoomey/vim-tmux-navigator' " navigate vim and tmux splits seamlessly call vundle#end() " required filetype plugin indent on " required @@ -121,5 +123,9 @@ " Intelligently navigate tmux panes and Vim splits using the same keys. " See https://sunaku.github.io/tmux-select-pane.html for documentation. let progname = substitute($VIM, '.*[/\\]', '', '') -set title titlestring=%{progname}\ %f\ +%l\ #%{tabpagenr()}.%{winnr()} +if empty(v:servername) + set title titlestring=%{progname}\ [%n]\ %F +else + set title titlestring=%{progname}\ [%{v:servername}]\ [%n]\ %F +endif if &term =~ '^screen' && !has('nvim') | exe "set t_ts=\e]2; t_fs=\7" | endif
tmux.conf Modified
@@ -18,43 +18,10 @@ set -g history-limit 5000 set -s escape-time 0 set -g base-index 1 - -# copy mode -# enter it with pre-[ -# select region with space -# copy with enter -# or quit with q -# paste it with pre=] -set-window-option -g mode-keys vi - -# Vim bindings in copy-mode -#bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "xclip -i -sel clip > /dev/null" -#bind-key p run "xclip -o -sel clip | tmux load-buffer - ; tmux paste-buffer" -#bind-key -T copy-mode-vi 'v' send -X begin-selection -#bind-key -T copy-mode-vi 'y' send -X copy-selection - -# status bar -#setw -g window-status-current-attr bold -#setw -g window-status-current-format ' #I#[fg=colour7]:#[fg=colour8]#W#[fg=colour7]#F ' -#set -g status-right '#[fg=colour8,bg=colour4,bold] %H:%M ' -#setw -g window-status-format ' #I#[fg=colour7]:#[fg=colour8]#W#[fg=colour7]#F ' set -g status off - -## Smart pane switching with awareness of Vim splits. -## See: https://github.com/christoomey/vim-tmux-navigator -#is_vim="ps -o state= -o comm= -t '#{pane_tty}' \ -# | grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'" -#bind-key -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L" -#bind-key -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D" -#bind-key -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U" -#bind-key -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R" -#bind-key -n C-\ if-shell "$is_vim" "send-keys C-\\" "select-pane -l" -#bind-key -T copy-mode-vi C-h select-pane -L -#bind-key -T copy-mode-vi C-j select-pane -D -#bind-key -T copy-mode-vi C-k select-pane -U -#bind-key -T copy-mode-vi C-l select-pane -R -#bind-key -T copy-mode-vi C-\ select-pane -l - +set -g set-titles on +set -g set-titles-string "[tmux] #T" +set-window-option -g mode-keys vi # Intelligently navigate tmux panes and Vim splits using the same keys. # See https://sunaku.github.io/tmux-select-pane.html for documentation. @@ -119,7 +86,6 @@ 'tmux send-keys C-w p' \ 'pane_is_zoomed' " -# QWERTY keys - comment these out if you don't use QWERTY layout! bind-key -n C-h run-shell -b "$navigate_left" bind-key -n C-j run-shell -b "$navigate_down" bind-key -n C-k run-shell -b "$navigate_up"