Fix tmux config on mac
This commit is contained in:
@@ -38,6 +38,7 @@ in
|
||||
|
||||
home.packages = with pkgs; [
|
||||
visidata
|
||||
codespelunker
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ in
|
||||
shortcut = "a";
|
||||
mouse = true;
|
||||
keyMode = "vi";
|
||||
escapeTime = 0;
|
||||
escapeTime = 10;
|
||||
terminal = "screen-256color";
|
||||
tmuxp.enable = true;
|
||||
extraConfig = ''
|
||||
@@ -22,16 +22,15 @@ in
|
||||
|
||||
unbind S
|
||||
bind S command-prompt "switch -t %1"
|
||||
bind-key , command-prompt -p "rename-window:" "rename-window '%%'"
|
||||
|
||||
# Check if we are in vim
|
||||
is_vim="ps -o state= -o comm= -t '#{pane_tty}' \
|
||||
| grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
|
||||
is_vim="ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
|
||||
|
||||
bind-key -n C-M-k if-shell "$is_vim" "send-keys C-M-k" "if -F \"#{pane_at_top}\" \"switch-client -p\" \"select-pane -U\""
|
||||
bind-key -n C-M-j if-shell "$is_vim" "send-keys C-M-j" "if -F \"#{pane_at_bottom}\" \"switch-client -n\" \"select-pane -D\""
|
||||
|
||||
bind-key -n C-M-l if-shell "$is_vim" "send-keys C-M-l" "if -F \"#{pane_at_right}\" \"next-window\" \"select-pane -R\""
|
||||
bind-key -n C-M-h if-shell "$is_vim" "send-keys C-M-h" "if -F \"#{pane_at_left}\" \"previous-window\" \"select-pane -L\""
|
||||
bind-key -n C-M-h if-shell "$is_vim" { send-keys C-M-h } { if -F "#{pane_at_left}" "previous-window" "select-pane -L" }
|
||||
bind-key -n C-M-j if-shell "$is_vim" { send-keys C-M-j } { if -F "#{pane_at_bottom}" "switch-client -n" "select-pane -D" }
|
||||
bind-key -n C-M-k if-shell "$is_vim" { send-keys C-M-k } { if -F "#{pane_at_top}" "switch-client -p" "select-pane -U" }
|
||||
bind-key -n C-M-l if-shell "$is_vim" { send-keys C-M-l } { if -F "#{pane_at_right}" "next-window" "select-pane -R" }
|
||||
|
||||
bind '"' split-window -c "#{pane_current_path}"
|
||||
bind % split-window -h -c "#{pane_current_path}"
|
||||
|
||||
@@ -19,7 +19,7 @@ vim.api.nvim_create_autocmd('FileType', {
|
||||
-- pattern = 'go',
|
||||
-- callback = function()
|
||||
-- require('dap-python').setup()
|
||||
-- require('dap-go').setup()
|
||||
require('dap-go').setup()
|
||||
|
||||
-- vim.lsp.enable('ruff')
|
||||
-- vim.lsp.config('ty')
|
||||
|
||||
Reference in New Issue
Block a user