home

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit ebc0a51e38774f861ecc3f59b9f695e86e1fb760
parent 261d9819e9282b31ec1eba0ab1b0830c0e0a7032
Author: Vincent Demeester <vincent@sbr.pm>
Date:   Mon,  6 Aug 2018 19:17:43 +0200

Try to configure tmux-plugin/tpm automagically

Signed-off-by: Vincent Demeester <vincent@sbr.pm>

Diffstat:
Mbase.nix | 15++++++++++++++-
Mhokkaido.nix | 1-
Moverlays/sbr.nix | 12+++++++-----
Mtmux/keybindings | 20++++++++++----------
Mtmux/tmux.conf | 10----------
5 files changed, 31 insertions(+), 27 deletions(-)

diff --git a/base.nix b/base.nix @@ -10,7 +10,20 @@ rec { path = https://github.com/vdemeester/home-manager/archive/fish-module.tar.gz; }; }; - home.file.".tmux.conf".source = ./tmux/tmux.conf; + home.file.".tmux.conf".text = '' + source-file $HOME/.config/tmux/tmux.conf + set-environment -g TMUX_PLUGIN_MANAGER_PATH '$HOME/.config/tmux/plugins' + + set -g @plugin 'tmux-plugins/tpm' + set -g @plugin 'tmux-plugins/tmux-resurrect' + set -g @plugin 'tmux-plugins/tmux-continuum' + set -g @plugin 'tmux-plugins/tmux-copycat' + + set -g @continuum-restore 'on' + + run '${pkgs.tmux-tpm}/tpm' +''; + xdg.configFile."tmux/tmux.conf".source = ./tmux/tmux.conf; xdg.configFile."tmux/commons/keybindings".source = ./tmux/keybindings; home.packages = with pkgs; [ jq diff --git a/hokkaido.nix b/hokkaido.nix @@ -13,6 +13,5 @@ ]; home.packages = with pkgs; [ vscode - weechat weechat-xmpp ]; } diff --git a/overlays/sbr.nix b/overlays/sbr.nix @@ -1,6 +1,9 @@ self: super: { - prm = import ../pkgs/prm { - inherit (super) stdenv lib buildGoPackage fetchgit; - }; -}- \ No newline at end of file + prm = import ../pkgs/prm { + inherit (super) stdenv lib buildGoPackage fetchgit; + }; + tmux-tpm = import ../pkgs/tmux-tpm { + inherit (super) stdenv lib fetchFromGitHub; + }; +} diff --git a/tmux/keybindings b/tmux/keybindings @@ -29,16 +29,16 @@ set -g mode-key vi # `PREFIX`-`ESCAPE` for going into copy mode bind-key ESCAPE copy-mode # Rebinding some vi-copy keys in a more bepoish fashion. -bind-key -t vi-copy 'v' begin-selection -bind-key -t vi-copy 'y' copy-selection -bind-key -t vi-copy 'C' top-line -bind-key -t vi-copy 'T' scroll-down -bind-key -t vi-copy 'S' scroll-up -bind-key -t vi-copy 'R' bottom-line -bind-key -t vi-copy 'c' cursor-left -bind-key -t vi-copy 't' cursor-down -bind-key -t vi-copy 's' cursor-up -bind-key -t vi-copy 'r' cursor-right +#bind-key -Tvi-copy 'v' begin-selection +#bind-key -Tvi-copy 'y' copy-selection +#bind-key -Tvi-copy 'C' top-line +#bind-key -Tvi-copy 'T' scroll-down +#bind-key -Tvi-copy 'S' scroll-up +#bind-key -Tvi-copy 'R' bottom-line +#bind-key -Tvi-copy 'c' cursor-left +#bind-key -Tvi-copy 't' cursor-down +#bind-key -Tvi-copy 's' cursor-up +#bind-key -Tvi-copy 'r' cursor-right # Telling childs that this is a 256 terminal multiplexer set -g default-terminal "screen-256color" # Maximizing/Restoring panes (useful for *a lot* of workflows) diff --git a/tmux/tmux.conf b/tmux/tmux.conf @@ -120,16 +120,6 @@ set -g message-fg colour232 set -g message-bg colour166 # } -set-environment -g TMUX_PLUGIN_MANAGER_PATH '$HOME/.config/tmux/plugins' - -set -g @plugin 'tmux-plugins/tpm' -set -g @plugin 'tmux-plugins/tmux-resurrect' -set -g @plugin 'tmux-plugins/tmux-continuum' -set -g @plugin 'tmux-plugins/tmux-copycat' - -set -g @continuum-restore 'on' - -run '~/.config/tmux/plugins/tpm/tpm' if 'command -v fish >/dev/null' \ 'set -g default-shell ~/.nix-profile/bin/fish' \ No newline at end of file