dotfiles

configuration files for shell, text editor, graphical environment, etc.
git clone git://src.adamsgaard.dk/dotfiles
Log | Files | Refs | README | LICENSE Back to index

commit 841be2a89c33dcc2e6242d411a88681675e7dd76
parent b7df476b3ce014998d71535697f6b782cfafcc5c
Author: Anders Damsgaard <anders@adamsgaard.dk>
Date:   Mon, 20 May 2019 16:57:21 +0200

Clean up tmux conf, revert to default screen scaling with displayselect

Diffstat:
M.local/bin/displayselect | 2++
M.tmux.conf | 37-------------------------------------
2 files changed, 2 insertions(+), 37 deletions(-)

diff --git a/.local/bin/displayselect b/.local/bin/displayselect @@ -82,6 +82,8 @@ if [ "$(echo "$screens" | wc -l)" -gt 1 ]; then "$(echo "$screens" | grep -v "$chosen" | \ awk '{print "--output", $1, "--off"}' | tr '\n' ' ')" ;; esac +else + xrandr --auto --scale 1.0x1.0 fi # Fix feh background if screen size/arangement has changed. diff --git a/.tmux.conf b/.tmux.conf @@ -55,10 +55,6 @@ if-shell 'uname | grep -qi Linux' "set -g status-right \"#[fg=cyan]#(~/bin/batte # Scaling of status-bar sections set -g status-right-length 40 -#set-hook client-resized "tmux set status-right-length `echo $(tmux display -p '#{client_width}')/3|bc|tr -d '\n'`; tmux set status-left-length `echo $(tmux display -p '#{client_width}'put cols)/3|bc|tr -d '\n'`" -#set-hook client-resized "display '#{client_width}'" -#set-hook client-resized 'display "#(tmux display -p \'#{client_width}/3\'|bc|tr -d \'\n\')"' -#set-hook client-resized "display '#(tmux display -p \'#{client_width}\'|tr -d \'\n\')'" #### NAVIGATION @@ -95,21 +91,6 @@ bind -n M-8 select-window -t :=8 bind -n M-9 select-window -t :=9 bind -n M-0 select-window -t :=10 -# 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 - bind C-s last-window # go to last window with <C-a><C-s> bind C-a last-pane # go to last pane with <C-a><C-a> bind -n M-s last-window # go to last pane with M-s @@ -130,11 +111,6 @@ bind -n M-. run-shell "tmux list-sessions -F \"##S\" | fzf-tmux | xargs tmux swi bind '"' split-window -c "#{pane_current_path}" bind '%' split-window -h -c "#{pane_current_path}" -# bind -n M-k split-window -b -c "#{pane_current_path}" # new split up -# bind -n M-j split-window -c "#{pane_current_path}" # new split down -# bind -n M-l split-window -h -c "#{pane_current_path}" # new split right -# bind -n M-h split-window -b -h -c "#{pane_current_path}" # new split left - bind -r z resize-pane -Z # toggle pane zoom with <C-a>z bind -r y next-layout # cycle to next pane layout with <C-a>y bind -r Y previous-layout # cycle to previous pane layout with <C-a>Y @@ -191,13 +167,8 @@ bind O split-window -p 25 '$SHELL -c "offlineimap"' \; select-pane -l bind -n C-M-v new-window -n vim "/usr/local/bin/vim" bind -n C-M-w new-window -n weather \ "curl 'wttr.in/?m'; echo -e '\nPress <enter> to quit'; read -n 1 -s" -#bind C-M-s split-window -l 2 \; send-keys "susan " -#bind C-M-h split-window -l 8 "htop" # Open new window and resize status accordingly (should be a hook instead) -#bind Enter new-window -#bind Enter new-window \ - #"tmux set status-right-length `echo $(tput cols)/2|bc|tr -d '\n'`; zsh" bind Enter new-window -c "#{pane_current_path}" "$SHELL" bind -n M-Enter new-window \ "tmux set status-right-length `echo $(tput cols)/2|bc|tr -d '\n'`; zsh" @@ -220,14 +191,6 @@ bind -n C-M-b display "#(mpc prev | tr '\n' ' ')" #bind -n C-M-r display "#(mpc clear && mpc ls | mpc add && mpc random on && mpc play | tr '\n' ' ')" bind -n C-M-a split-window -p 50 "source ~/code/fzf-mpd/fzf-mpd.zsh && fm" -# Use alternate prefix (C-b) for grouping music-control bindings -#bind -n C-b switchc -Tmoreprefix -#bind -n -Tmoreprefix v new-window -n vimpc "vimpc" -#bind -n -Tmoreprefix p new-window -n mpc "mpc toggle" -#bind -n -Tmoreprefix s new-window -n mpc "mpc stop" -#bind -n -Tmoreprefix n new-window -n mpc "mpc next" -#bind -n -Tmoreprefix b new-window -n mpc "mpc prev" - # fzf-locate from entire file system and insert result in current pane (Alt-`) bind -n 'M-`' run "tmux split-window -p 40 'tmux send-keys -t #{pane_id} \"$(locate / | fzf -m | paste -sd\\ -)\"'"