From c146ff0f95ad85df74b1c903487d2327967ea217 Mon Sep 17 00:00:00 2001 From: Dreaded_X Date: Wed, 4 Jun 2025 01:22:31 +0200 Subject: [PATCH] Make nvim pane switching work when inside devcontainer --- zsh/dot-zshrc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/zsh/dot-zshrc b/zsh/dot-zshrc index dc7d8c2..afeec05 100644 --- a/zsh/dot-zshrc +++ b/zsh/dot-zshrc @@ -68,7 +68,13 @@ if hash devcontainer 2>/dev/null; then if find "$PWD"/ -maxdepth 1 -type d -name ".devcontainer" | grep -q ".devcontainer"; then WORKSPACE_FOLDER="$PWD" builtin cd "$ORIG_DIR" + + if [[ "$1" == "nvim" ]]; then + tmux set-option -pt 0 @pane-is-vim 1 + fi + devcontainer exec --workspace-folder "$WORKSPACE_FOLDER" $@ + tmux set-option -pt 0 @pane-is-vim 0 return 0 else builtin cd ..