Worktrunk is a CLI for Git worktree management, designed for parallel AI agent workflows
feat(switch): deprecate shell command lines in --execute (#2852)
Maximilian Roos93b441c8f015
diff --git a/docs/content/switch.md b/docs/content/switch.mdindex 129987b78..b45a4c474 100644--- a/docs/content/switch.md+++ b/docs/content/switch.md@@ -172,8 +172,8 @@ Usage: <b><span class=c>wt switch</span></b> <span class=c>[OPTIONS]</span> <spaare passed to the command, so <b>wsc feature -- 'Fix GH #322'</b> runs <b>claude 'Fix GH #322'</b>,starting Claude with a prompt.- Template example: <b>-x 'code {{ worktree_path }}'</b> opens VS Code at the worktree, <b>-x 'tmux</b>-<b> new -s {{ branch | sanitize }}'</b> starts a tmux session named after the branch.+ Template example: <b>-x code -- '{{ worktree_path }}'</b> opens VS Code at the worktree, <b>-x tmux</b>+<b> -- new -s '{{ branch | sanitize }}'</b> starts a tmux session named after the branch.<b><span class=c>--clobber</span></b>Remove stale paths at targetdiff --git a/skills/worktrunk/reference/switch.md b/skills/worktrunk/reference/switch.mdindex b8106691a..3c7e5fc4f 100644--- a/skills/worktrunk/reference/switch.md+++ b/skills/worktrunk/reference/switch.md@@ -164,8 +164,8 @@ Options:are passed to the command, so wsc feature -- 'Fix GH #322' runs claude 'Fix GH #322',starting Claude with a prompt.- Template example: -x 'code {{ worktree_path }}' opens VS Code at the worktree, -x 'tmux- new -s {{ branch | sanitize }}' starts a tmux session named after the branch.+ Template example: -x code -- '{{ worktree_path }}' opens VS Code at the worktree, -x tmux+ -- new -s '{{ branch | sanitize }}' starts a tmux session named after the branch.--clobberRemove stale paths at targetdiff --git a/src/cli/mod.rs b/src/cli/mod.rsindex e26a11422..c5b1db164 100644--- a/src/cli/mod.rs+++ b/src/cli/mod.rs@@ -316,8 +316,8 @@ pub(crate) struct SwitchArgs {/// `wsc feature -- 'Fix GH #322'` runs `claude 'Fix GH #322'`,/// starting Claude with a prompt.///- /// Template example: `-x 'code {{ worktree_path }}'` opens VS Code- /// at the worktree, `-x 'tmux new -s {{ branch | sanitize }}'` starts+ /// Template example: `-x code -- '{{ worktree_path }}'` opens VS Code+ /// at the worktree, `-x tmux -- new -s '{{ branch | sanitize }}'` starts/// a tmux session named after the branch.#[arg(short = 'x', long, requires = "branch")]pub(crate) execute: Option<String>,diff --git a/src/commands/worktree/switch.rs b/src/commands/worktree/switch.rsindex c0d4715c6..56c1c7bd9 100644--- a/src/commands/worktree/switch.rs+++ b/src/commands/worktree/switch.rs@@ -1953,6 +1953,84 @@ pub fn run_switch(.run()}+/// Whether `value` is a single clean program-name token — the form `--execute`+/// keeps accepting unchanged once it switches to the argv input model.+///+/// First character `[A-Za-z0-9._/@]`, the rest additionally `+`/`-`. On+/// Windows, `\` and `:` are also allowed so native paths (`C:\dir\tool`) are+/// not flagged; on POSIX they are shell metacharacters and stay excluded.+/// This rejects a leading `-`/`+` (an option-like `argv[0]` resolves+/// differently), whitespace, `{{ }}` template markup, and every shell+/// metacharacter — any of which means the value is not a bare program name.+fn is_clean_program_token(value: &str) -> bool {+ let mut chars = value.chars();+ let Some(first) = chars.next() else {+ return false;+ };+ let first_ok = first.is_ascii_alphanumeric()+ || matches!(first, '.' | '_' | '/' | '@')+ || (cfg!(windows) && first == '\\');+ first_ok+ && chars.all(|c| {+ c.is_ascii_alphanumeric()+ || matches!(c, '.' | '_' | '/' | '@' | '+' | '-')+ || (cfg!(windows) && matches!(c, '\\' | ':'))+ })+}++/// Warn when a `--execute` value will change behavior under the upcoming argv+/// input model.+///+/// A future release runs `-x` as a single program (with arguments after `--`),+/// not a shell command line. Warn now for any value that is not a single+/// program token — shell syntax, multiple words, or `{{ }}` markup (flagged+/// conservatively, even when it would expand to a clean name).+///+/// A single program token — including a path — is unaffected and stays silent.+/// A bare name that is really a shell alias/function/builtin is not detectable+/// here without the user's shell, so it is left to fail loudly at the cutover+/// rather than guessed at. Informational only — it never blocks the switch.+///+/// The migration hint reconstructs the command line that runs today — the+/// `-x` value with its trailing args appended, the way `run_switch` joins+/// them — and wraps it for whichever shell the active wrapper evaluates the+/// payload with (`sh` / `fish` / `pwsh`). That keeps the suggestion+/// behavior-preserving on fish/PowerShell, not just POSIX sh, and complete+/// when trailing args are present.+fn warn_if_execute_form_deprecated(cmd: &str, execute_args: &[String]) {+ if is_clean_program_token(cmd) {+ return;+ }+ let mode = directive_shell_escape_mode();+ let (shell, flag) = match mode {+ ShellEscapeMode::PowerShell => ("pwsh", "-Command"),+ ShellEscapeMode::Fish => ("fish", "-c"),+ _ => ("sh", "-c"),+ };+ let command_line = if execute_args.is_empty() {+ cmd.to_string()+ } else {+ let escaped: Vec<String> = execute_args+ .iter()+ .map(|arg| shell_escape_for(mode, arg))+ .collect();+ format!("{} {}", cmd, escaped.join(" "))+ };+ let suggested = shell_escape_for(mode, &command_line);+ eprintln!(+ "{}",+ warning_message(cformat!(+ "<bold>--execute</> will change in a future release: it will run a single program, with arguments after <bold>--</>, not a shell command line"+ ))+ );+ eprintln!(+ "{}",+ hint_message(cformat!(+ "To run this command line unchanged, pass it to a shell: <underline>--execute {shell} -- {flag} {suggested}</>"+ ))+ );+}+/// Validate all templates that will be expanded after worktree creation.////// Catches syntax errors and undefined variable references *before* the@@ -2012,6 +2090,7 @@ fn validate_switch_templates("--execute argument",)?;}+ warn_if_execute_form_deprecated(cmd, execute_args);}// Validate hook templates only when hooks will actually run@@ -2056,6 +2135,45 @@ mod tests {use super::*;use worktrunk::testing::TestRepo;+ #[test]+ fn is_clean_program_token_matches_only_bare_names() {+ // Bare program names — unchanged under the argv input model.+ for ok in [+ "git",+ "claude",+ "node18",+ "my-tool",+ "tool.sh",+ "/usr/bin/env",+ "./build",+ "_x",+ "@scope/pkg",+ ] {+ assert!(is_clean_program_token(ok), "expected clean token: {ok:?}");+ }+ // Not bare names — empty, whitespace, shell syntax, template markup,+ // or an option-like leading character.+ for bad in [+ "",+ "npm run dev",+ "a && b",+ "echo $HOME",+ "code {{ worktree_path }}",+ "a|b",+ "-flag",+ "+x",+ ] {+ assert!(!is_clean_program_token(bad), "expected non-token: {bad:?}");+ }+ // A native Windows path is a clean token only when targeting Windows;+ // on POSIX, `\` and `:` are shell metacharacters.+ assert_eq!(+ is_clean_program_token(r"C:\Tools\foo.exe"),+ cfg!(windows),+ "Windows path classification should follow the target OS"+ );+ }+#[test]fn capture_switch_source_returns_empty_when_recovered() {// When recovered from a deleted CWD, post-switch hooks must see emptydiff --git a/tests/integration_tests/shell_wrapper.rs b/tests/integration_tests/shell_wrapper.rsindex c518d03ef..8c36ff02b 100644--- a/tests/integration_tests/shell_wrapper.rs+++ b/tests/integration_tests/shell_wrapper.rs@@ -952,7 +952,8 @@ mod unix_tests {#[case("fish")]#[case("nu")]fn test_wrapper_switch_with_execute(#[case] shell: &str, repo: TestRepo) {- // Use --yes to skip approval prompt in tests+ // `echo` with `executed` as a trailing arg, run through each wrapper.+ // `--yes` skips the approval prompt.let output = exec_through_wrapper(shell,&repo,@@ -960,9 +961,11 @@ mod unix_tests {&["--create","test-exec",- "--execute",- "echo executed","--yes",+ "--execute",+ "echo",+ "--",+ "executed",],);@@ -976,11 +979,11 @@ mod unix_tests {shell);- // Consolidated snapshot - output should be identical across all shells+ // Per-shell snapshot: the `Executing (--execute):` line escapes the+ // trailing arg for the directive shell, so fish differs from the+ // POSIX wrappers — output is no longer identical across shells.shell_wrapper_settings().bind(|| {- insta::allow_duplicates! {- assert_snapshot!("switch_with_execute", &output.combined);- }+ assert_snapshot!(format!("switch_with_execute_{shell}"), &output.combined);});}diff --git a/tests/integration_tests/switch.rs b/tests/integration_tests/switch.rsindex c19147d3b..9556d1056 100644--- a/tests/integration_tests/switch.rs+++ b/tests/integration_tests/switch.rs@@ -668,6 +668,62 @@ fn test_switch_with_execute_trailing_args_metachars_fish(repo: TestRepo) {);});}++/// A `--execute` value that is a shell command line rather than a single+/// program name gets a deprecation warning for the upcoming argv input model;+/// a single program name stays silent.+#[rstest]+fn test_switch_execute_argv_deprecation_warning(repo: TestRepo) {+ let (cd_path, exec_path, _guard) = directive_files();+ let settings = setup_snapshot_settings(&repo);+ settings.bind(|| {+ // Shell syntax / multiple words — not a single program name.+ let mut cmd = make_snapshot_cmd(+ &repo,+ "switch",+ &["--create", "dep-shell", "--execute", "echo hi && ls"],+ None,+ );+ configure_directive_files(&mut cmd, &cd_path, &exec_path);+ assert_cmd_snapshot!("switch_execute_deprecation_shell_syntax", cmd);++ // A single program name — unaffected, no warning.+ let mut cmd = make_snapshot_cmd(+ &repo,+ "switch",+ &["--create", "dep-ok", "--execute", "git"],+ None,+ );+ configure_directive_files(&mut cmd, &cd_path, &exec_path);+ assert_cmd_snapshot!("switch_execute_deprecation_compatible", cmd);++ // Trailing args are folded into the suggested command line, not dropped.+ let mut cmd = make_snapshot_cmd(+ &repo,+ "switch",+ &["--create", "dep-args", "--execute", "npm run", "--", "test"],+ None,+ );+ configure_directive_files(&mut cmd, &cd_path, &exec_path);+ assert_cmd_snapshot!("switch_execute_deprecation_trailing_args", cmd);++ // Under a fish wrapper the suggestion wraps in `fish`, not POSIX `sh`.+ let mut cmd = make_snapshot_cmd(+ &repo,+ "switch",+ &[+ "--create",+ "dep-fish",+ "--execute",+ "set -lx FOO bar; echo $FOO",+ ],+ None,+ );+ configure_directive_files(&mut cmd, &cd_path, &exec_path);+ cmd.env("WORKTRUNK_SHELL", "fish");+ assert_cmd_snapshot!("switch_execute_deprecation_fish_wrapper", cmd);+ });+}// Error tests#[rstest]fn test_switch_error_missing_worktree_directory(mut repo: TestRepo) {diff --git a/tests/snapshots/integration__integration_tests__directives__switch_exec_scrubbed_warns.snap b/tests/snapshots/integration__integration_tests__directives__switch_exec_scrubbed_warns.snapindex 3b10e6fa2..bdf051606 100644--- a/tests/snapshots/integration__integration_tests__directives__switch_exec_scrubbed_warns.snap+++ b/tests/snapshots/integration__integration_tests__directives__switch_exec_scrubbed_warns.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -34,13 +40,19 @@ info:WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo should-not-run'[24m[22m[32m✓[39m [32mCreated branch [1mscrub-test[22m from [1mmain[22m and worktree @ [1m_REPO_.scrub-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33m[1m--execute[22m disabled inside project alias / hook bodies for safety; skipping [1mecho should-not-run[22m[39mdiff --git a/tests/snapshots/integration__integration_tests__directives__switch_legacy_directive_file_with_execute.snap b/tests/snapshots/integration__integration_tests__directives__switch_legacy_directive_file_with_execute.snapindex ff8bf406d..94abc5858 100644--- a/tests/snapshots/integration__integration_tests__directives__switch_legacy_directive_file_with_execute.snap+++ b/tests/snapshots/integration__integration_tests__directives__switch_legacy_directive_file_with_execute.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -34,13 +40,19 @@ info:WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_DIRECTIVE_FILE: "[DIRECTIVE_FILE]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo hello'[24m[22m[32m✓[39m [32mCreated branch [1mexec-legacy[22m from [1mmain[22m and worktree @ [1m_REPO_.exec-legacy[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[36m◎[39m [36mExecuting (--execute):[39mdiff --git a/tests/snapshots/integration__integration_tests__help__help_switch_long.snap b/tests/snapshots/integration__integration_tests__help__help_switch_long.snapindex 8ac22d88f..b7b34f023 100644--- a/tests/snapshots/integration__integration_tests__help__help_switch_long.snap+++ b/tests/snapshots/integration__integration_tests__help__help_switch_long.snap@@ -75,7 +75,7 @@ Usage: [1m[36mwt switch[0m [36m[OPTIONS][0m [36m[BRANCH][0m [1m[36m[--[0mThen [1mwsc feature-branch[0m creates the worktree and launches Claude Code. Arguments after [1m--[0m are passed to the command, so [1mwsc feature -- 'Fix GH #322'[0m runs [1mclaude 'Fix GH #322'[0m, starting Claude with a prompt.[0m- Template example: [1m-x 'code {{ worktree_path }}'[0m opens VS Code at the worktree, [1m-x 'tmux new -s {{ branch | sanitize }}'[0m starts a tmux session named after the branch.[0m+ Template example: [1m-x code -- '{{ worktree_path }}'[0m opens VS Code at the worktree, [1m-x tmux -- new -s '{{ branch | sanitize }}'[0m starts a tmux session named after the branch.[0m[1m[36m--clobber[0mRemove stale paths at targetdiff --git a/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snap b/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snapindex 70407b37e..67dddc252 100644--- a/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snap+++ b/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snap@@ -59,6 +59,8 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''Execute flag'\'' > execute.txt'[24m[22m[32m✓[39m [32mCreated branch [1mfeature[22m from [1mmain[22m and worktree @ [1m_REPO_.feature[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_multiline_command_execution.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_multiline_command_execution.snapindex ca3e620db..d18437555 100644--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_multiline_command_execution.snap+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_multiline_command_execution.snap@@ -3,6 +3,8 @@ source: tests/integration_tests/shell_wrapper.rsexpression: "&output.combined"---+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute fish -- -c 'echo \'line 1\'; echo \'line 2\'; echo \'line 3\''[24m[22m[32m✓[39m [32mCreated branch [1mfish-multiline[22m from [1mmain[22m and worktree @ [1m_REPO_.fish-multiline[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[36m◎[39m [36mExecuting (--execute):[39mdiff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_bash.snapsimilarity index 100%rename from tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute.snaprename to tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_bash.snapdiff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_fish.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_fish.snapnew file mode 100644index 000000000..057720d70--- /dev/null+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_fish.snap@@ -0,0 +1,10 @@+---+source: tests/integration_tests/shell_wrapper.rs+expression: "&output.combined"+---++[32m✓[39m [32mCreated branch [1mtest-exec[22m from [1mmain[22m and worktree @ [1m_REPO_.test-exec[22m[39m+[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m+[36m◎[39m [36mExecuting (--execute):[39m+[107m [0m [2m[0m[2m[34mecho[0m[2m [0m[2m[32m'executed'[0m[2m+executeddiff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_nu.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_nu.snapnew file mode 100644index 000000000..e07d7519c--- /dev/null+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_nu.snap@@ -0,0 +1,10 @@+---+source: tests/integration_tests/shell_wrapper.rs+expression: "&output.combined"+---++[32m✓[39m [32mCreated branch [1mtest-exec[22m from [1mmain[22m and worktree @ [1m_REPO_.test-exec[22m[39m+[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m+[36m◎[39m [36mExecuting (--execute):[39m+[107m [0m [2m[0m[2m[34mecho[0m[2m executed+executeddiff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_through_wrapper.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_through_wrapper.snapindex e07d7519c..cdca1d39c 100644--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_through_wrapper.snap+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_through_wrapper.snap@@ -3,6 +3,8 @@ source: tests/integration_tests/shell_wrapper.rsexpression: "&output.combined"---+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo executed'[24m[22m[32m✓[39m [32mCreated branch [1mtest-exec[22m from [1mmain[22m and worktree @ [1m_REPO_.test-exec[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[36m◎[39m [36mExecuting (--execute):[39mdiff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_zsh.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_zsh.snapnew file mode 100644index 000000000..e07d7519c--- /dev/null+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_execute_zsh.snap@@ -0,0 +1,10 @@+---+source: tests/integration_tests/shell_wrapper.rs+expression: "&output.combined"+---++[32m✓[39m [32mCreated branch [1mtest-exec[22m from [1mmain[22m and worktree @ [1m_REPO_.test-exec[22m[39m+[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m+[36m◎[39m [36mExecuting (--execute):[39m+[107m [0m [2m[0m[2m[34mecho[0m[2m executed+executeddiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_creates_file.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_creates_file.snapindex bca2ae910..acc1eb447 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_creates_file.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_creates_file.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -47,6 +59,8 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''test content'\'' > test.txt'[24m[22m[32m✓[39m [32mCreated branch [1mfile-test[22m from [1mmain[22m and worktree @ [1m_REPO_.file-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_compatible.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_compatible.snapnew file mode 100644index 000000000..8971c821e--- /dev/null+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_compatible.snap@@ -0,0 +1,66 @@+---+source: tests/integration_tests/switch.rs+info:+ program: wt+ args:+ - switch+ - "--create"+ - dep-ok+ - "--execute"+ - git+ env:+ APPDATA: "[TEST_CONFIG_HOME]"+ CLICOLOR_FORCE: "1"+ COLUMNS: "500"+ GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""+ GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"+ GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""+ GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""+ GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""+ HOME: "[TEST_HOME]"+ LANG: C+ LC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"+ MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"+ NO_COLOR: ""+ OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"+ PATH: "[PATH]"+ PSModulePath: ""+ RUST_LOG: warn+ SHELL: ""+ TERM: alacritty+ USERPROFILE: "[TEST_HOME]"+ WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"+ WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"+ WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"+ WORKTRUNK_DIRECTIVE_EXEC_FILE: "[DIRECTIVE_EXEC_FILE]"+ WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"+ WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"+ WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"+ WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"+ WORKTRUNK_TEST_NUSHELL_ENV: "0"+ WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"+ WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"+ WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"+ XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"+---+success: true+exit_code: 0+----- stdout -----++----- stderr -----+[32m✓[39m [32mCreated branch [1mdep-ok[22m from [1mmain[22m and worktree @ [1m_REPO_.dep-ok[22m[39m+[36m◎[39m [36mExecuting (--execute):[39m+[107m [0m [2m[0m[2m[34mgit[0m[2mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_fish_wrapper.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_fish_wrapper.snapnew file mode 100644index 000000000..c56ed6d43--- /dev/null+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_fish_wrapper.snap@@ -0,0 +1,69 @@+---+source: tests/integration_tests/switch.rs+info:+ program: wt+ args:+ - switch+ - "--create"+ - dep-fish+ - "--execute"+ - set -lx FOO bar; echo $FOO+ env:+ APPDATA: "[TEST_CONFIG_HOME]"+ CLICOLOR_FORCE: "1"+ COLUMNS: "500"+ GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""+ GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"+ GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""+ GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""+ GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""+ HOME: "[TEST_HOME]"+ LANG: C+ LC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"+ MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"+ NO_COLOR: ""+ OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"+ PATH: "[PATH]"+ PSModulePath: ""+ RUST_LOG: warn+ SHELL: ""+ TERM: alacritty+ USERPROFILE: "[TEST_HOME]"+ WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"+ WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"+ WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"+ WORKTRUNK_DIRECTIVE_EXEC_FILE: "[DIRECTIVE_EXEC_FILE]"+ WORKTRUNK_SHELL: fish+ WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"+ WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"+ WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"+ WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"+ WORKTRUNK_TEST_NUSHELL_ENV: "0"+ WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"+ WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"+ WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"+ XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"+---+success: true+exit_code: 0+----- stdout -----++----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute fish -- -c 'set -lx FOO bar; echo $FOO'[24m[22m+[32m✓[39m [32mCreated branch [1mdep-fish[22m from [1mmain[22m and worktree @ [1m_REPO_.dep-fish[22m[39m+[36m◎[39m [36mExecuting (--execute):[39m+[107m [0m [2m[0m[2m[34mset[0m[2m [0m[2m[36m-lx[0m[2m FOO bar; [0m[2m[34mecho[0m[2m [0m[2m[36m$[0m[2mFOOdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_shell_syntax.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_shell_syntax.snapnew file mode 100644index 000000000..34037c9be--- /dev/null+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_shell_syntax.snap@@ -0,0 +1,69 @@+---+source: tests/integration_tests/switch.rs+info:+ program: wt+ args:+ - switch+ - "--create"+ - dep-shell+ - "--execute"+ - echo hi && ls+ env:+ APPDATA: "[TEST_CONFIG_HOME]"+ CLICOLOR_FORCE: "1"+ COLUMNS: "500"+ GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""+ GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"+ GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""+ GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""+ GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""+ HOME: "[TEST_HOME]"+ LANG: C+ LC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"+ MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"+ NO_COLOR: ""+ OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"+ PATH: "[PATH]"+ PSModulePath: ""+ RUST_LOG: warn+ SHELL: ""+ TERM: alacritty+ USERPROFILE: "[TEST_HOME]"+ WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"+ WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"+ WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"+ WORKTRUNK_DIRECTIVE_EXEC_FILE: "[DIRECTIVE_EXEC_FILE]"+ WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"+ WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"+ WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"+ WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"+ WORKTRUNK_TEST_NUSHELL_ENV: "0"+ WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"+ WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"+ WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"+ XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"+---+success: true+exit_code: 0+----- stdout -----++----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo hi && ls'[24m[22m+[32m✓[39m [32mCreated branch [1mdep-shell[22m from [1mmain[22m and worktree @ [1m_REPO_.dep-shell[22m[39m+[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m+[36m◎[39m [36mExecuting (--execute):[39m+[107m [0m [2m[0m[2m[34mecho[0m[2m hi [0m[2m[36m&&[0m[2m [0m[2m[34mls[0m[2mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_trailing_args.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_trailing_args.snapnew file mode 100644index 000000000..bf6de2fe8--- /dev/null+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_deprecation_trailing_args.snap@@ -0,0 +1,70 @@+---+source: tests/integration_tests/switch.rs+info:+ program: wt+ args:+ - switch+ - "--create"+ - dep-args+ - "--execute"+ - npm run+ - "--"+ - test+ env:+ APPDATA: "[TEST_CONFIG_HOME]"+ CLICOLOR_FORCE: "1"+ COLUMNS: "500"+ GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""+ GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"+ GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""+ GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""+ GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""+ HOME: "[TEST_HOME]"+ LANG: C+ LC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"+ MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"+ NO_COLOR: ""+ OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"+ PATH: "[PATH]"+ PSModulePath: ""+ RUST_LOG: warn+ SHELL: ""+ TERM: alacritty+ USERPROFILE: "[TEST_HOME]"+ WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"+ WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"+ WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"+ WORKTRUNK_DIRECTIVE_EXEC_FILE: "[DIRECTIVE_EXEC_FILE]"+ WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"+ WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"+ WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"+ WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"+ WORKTRUNK_TEST_NUSHELL_ENV: "0"+ WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"+ WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"+ WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"+ XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"+---+success: true+exit_code: 0+----- stdout -----++----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'npm run test'[24m[22m+[32m✓[39m [32mCreated branch [1mdep-args[22m from [1mmain[22m and worktree @ [1m_REPO_.dep-args[22m[39m+[36m◎[39m [36mExecuting (--execute):[39m+[107m [0m [2m[0m[2m[34mnpm[0m[2m run testdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_existing.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_existing.snapindex 9b58f85b3..a5c3edefd 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_existing.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_existing.snap@@ -13,13 +13,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -32,13 +38,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -46,6 +58,8 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''existing worktree'\'' > existing.txt'[24m[22m[33m▲[39m [33mWorktree for [1mexisting-exec[22m @ [1m_REPO_.existing-exec[22m, but cannot change directory — shell integration not installed[39m[2m↳[22m [2mTo enable automatic cd, run [4mwt config shell install[24m[22m[36m◎[39m [36mExecuting (--execute) @ [1m_REPO_.existing-exec[22m:[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_failure.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_failure.snapindex 1d3dc7dcd..a93111ddf 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_failure.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_failure.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: false@@ -47,6 +59,8 @@ exit_code: 1----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'exit 1'[24m[22m[32m✓[39m [32mCreated branch [1mfail-test[22m from [1mmain[22m and worktree @ [1m_REPO_.fail-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_multiline.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_multiline.snapindex 0d1c2ef31..e0d58350a 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_multiline.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_multiline.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -50,6 +62,10 @@ line2line3----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''line1'\''+echo '\''line2'\''+echo '\''line3'\'''[24m[22m[32m✓[39m [32mCreated branch [1mmultiline-test[22m from [1mmain[22m and worktree @ [1m_REPO_.multiline-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_success.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_success.snapindex 8fa4d2f6c..b78c74e54 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_success.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_success.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0test output----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''test output'\'''[24m[22m[32m✓[39m [32mCreated branch [1mexec-test[22m from [1mmain[22m and worktree @ [1m_REPO_.exec-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base.snapindex 88775394e..d1ef79cc0 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base.snap@@ -16,13 +16,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -35,13 +41,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -50,6 +62,8 @@ exit_code: 0base=main----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''base={{ base }}'\'''[24m[22m[32m✓[39m [32mCreated branch [1mfrom-main[22m from [1mmain[22m and worktree @ [1m_REPO_.from-main[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base_without_create.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base_without_create.snapindex 4d57aea06..e849a937e 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base_without_create.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_base_without_create.snap@@ -13,13 +13,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -32,13 +38,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -47,6 +59,8 @@ exit_code: 0base=main----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''base={{ base }}'\'''[24m[22m[33m▲[39m [33mWorktree for [1mexisting[22m @ [1m_REPO_.existing[22m, but cannot change directory — shell integration not installed[39m[2m↳[22m [2mTo enable automatic cd, run [4mwt config shell install[24m[22m[36m◎[39m [36mExecuting (--execute) @ [1m_REPO_.existing[22m:[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_branch.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_branch.snapindex ec16a0389..be59b9fd7 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_branch.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_branch.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0branch=template-test----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''branch={{ branch }}'\'''[24m[22m[32m✓[39m [32mCreated branch [1mtemplate-test[22m from [1mmain[22m and worktree @ [1m_REPO_.template-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_shell_escape.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_shell_escape.snapindex 78fd99559..ac6849690 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_shell_escape.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_shell_escape.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0feat;id----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo {{ branch }}'[24m[22m[32m✓[39m [32mCreated branch [1mfeat;id[22m from [1mmain[22m and worktree @ [1m'_REPO_.feat;id'[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_with_filter.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_with_filter.snapindex d10235096..059fbc36a 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_with_filter.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_with_filter.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0sanitized=feature-with-slash----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''sanitized={{ branch | sanitize }}'\'''[24m[22m[32m✓[39m [32mCreated branch [1mfeature/with-slash[22m from [1mmain[22m and worktree @ [1m_REPO_.feature-with-slash[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_worktree_path.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_worktree_path.snapindex e54bd271c..2353df985 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_template_worktree_path.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_template_worktree_path.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0path=_REPO_.path-test----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''path={{ worktree_path }}'\'''[24m[22m[32m✓[39m [32mCreated branch [1mpath-test[22m from [1mmain[22m and worktree @ [1m_REPO_.path-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_multiline_template.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_multiline_template.snapindex 6f75a50e0..643eecf6d 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_multiline_template.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_multiline_template.snap@@ -15,13 +15,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -34,13 +40,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -54,6 +66,11 @@ repo=repo[107m [0m [2m[0m[2m[32m{{[0m[2m[0m[2m repo_path [0m[2m[32m}}[0m[2m/../[0m[2m[32m{{[0m[2m repo [0m[2m[32m}}[0m[2m.[0m[2m[32m{{[0m[2m branch [0m[2m[36m|[0m[2m [0m[2m[34msanitize[0m[2m [0m[2m[32m}}[0m[2m[107m [0m [2m→[22m[107m [0m [2m[0m[2m[34m_REPO_/../repo.multiline-test[0m[2m+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c '{% if branch %}+echo '\''branch={{ branch }}'\''+echo '\''repo={{ repo }}'\''+{% endif %}'[24m[22m[32m✓[39m [32mCreated branch [1mmultiline-test[22m from [1mmain[22m and worktree @ [1m_REPO_.multiline-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_template.snap b/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_template.snapindex 371513a47..da7f6bae2 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_template.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_execute_verbose_template.snap@@ -15,13 +15,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -34,13 +40,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -53,6 +65,8 @@ branch=verbose-test[107m [0m [2m[0m[2m[32m{{[0m[2m[0m[2m repo_path [0m[2m[32m}}[0m[2m/../[0m[2m[32m{{[0m[2m repo [0m[2m[32m}}[0m[2m.[0m[2m[32m{{[0m[2m branch [0m[2m[36m|[0m[2m [0m[2m[34msanitize[0m[2m [0m[2m[32m}}[0m[2m[107m [0m [2m→[22m[107m [0m [2m[0m[2m[34m_REPO_/../repo.verbose-test[0m[2m+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''branch={{ branch }}'\'''[24m[22m[32m✓[39m [32mCreated branch [1mverbose-test[22m from [1mmain[22m and worktree @ [1m_REPO_.verbose-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_exit_code.snap b/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_exit_code.snapindex 9a1468a87..5ec7bad33 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_exit_code.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_exit_code.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -35,13 +41,19 @@ info:WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"WORKTRUNK_DIRECTIVE_EXEC_FILE: "[DIRECTIVE_EXEC_FILE]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -49,6 +61,8 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'exit 42'[24m[22m[32m✓[39m [32mCreated branch [1mexit-code-test[22m from [1mmain[22m and worktree @ [1m_REPO_.exit-code-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[36m◎[39m [36mExecuting (--execute):[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_output_then_exit.snap b/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_output_then_exit.snapindex d728c8382..017fbc3c3 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_output_then_exit.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_internal_execute_output_then_exit.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -35,13 +41,19 @@ info:WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"WORKTRUNK_DIRECTIVE_EXEC_FILE: "[DIRECTIVE_EXEC_FILE]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -49,6 +61,9 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''doing work'\''+exit 7'[24m[22m[32m✓[39m [32mCreated branch [1moutput-exit-test[22m from [1mmain[22m and worktree @ [1m_REPO_.output-exit-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[36m◎[39m [36mExecuting (--execute):[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_internal_with_execute.snap b/tests/snapshots/integration__integration_tests__switch__switch_internal_with_execute.snapindex 53fdcfc2f..96f688990 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_internal_with_execute.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_internal_with_execute.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -35,13 +41,19 @@ info:WORKTRUNK_DIRECTIVE_CD_FILE: "[DIRECTIVE_CD_FILE]"WORKTRUNK_DIRECTIVE_EXEC_FILE: "[DIRECTIVE_EXEC_FILE]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -49,6 +61,9 @@ exit_code: 0----- stdout ---------- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''line1'\''+echo '\''line2'\'''[24m[22m[32m✓[39m [32mCreated branch [1mexec-internal[22m from [1mmain[22m and worktree @ [1m_REPO_.exec-internal[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[36m◎[39m [36mExecuting (--execute):[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_execute_still_runs.snap b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_execute_still_runs.snapindex ab262a605..083f3dfb1 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_execute_still_runs.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_execute_still_runs.snap@@ -15,13 +15,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -34,13 +40,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -49,6 +61,8 @@ exit_code: 0execute command runs----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''execute command runs'\'''[24m[22m[32m✓[39m [32mCreated branch [1mno-hooks-test[22m from [1mmain[22m and worktree @ [1m_REPO_.no-hooks-test[22m[39m[2m↳[22m [2mTo customize worktree locations, run [4mwt config create[24m[22m[33m▲[39m [33mCannot change directory — shell integration not installed[39mdiff --git a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_existing.snap b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_existing.snapindex 2c524b310..3ff221ff3 100644--- a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_existing.snap+++ b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_existing.snap@@ -14,13 +14,19 @@ info:COLUMNS: "500"GIT_AUTHOR_DATE: "2025-01-01T00:00:00Z"GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"+ GIT_COMMON_DIR: ""GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"GIT_CONFIG_SYSTEM: /dev/null+ GIT_DIR: ""GIT_EDITOR: ""+ GIT_INDEX_FILE: ""+ GIT_OBJECT_DIRECTORY: ""GIT_TERMINAL_PROMPT: "0"+ GIT_WORK_TREE: ""HOME: "[TEST_HOME]"LANG: CLC_ALL: C+ LLVM_PROFILE_FILE: "[LLVM_PROFILE_FILE]"MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"@@ -33,13 +39,19 @@ info:WORKTRUNK_APPROVALS_PATH: "[TEST_APPROVALS]"WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"WORKTRUNK_SYSTEM_CONFIG_PATH: "[TEST_SYSTEM_CONFIG]"+ WORKTRUNK_TEST_BASH_INSTALLED: "0"WORKTRUNK_TEST_CLAUDE_INSTALLED: "0"+ WORKTRUNK_TEST_CODEX_INSTALLED: "0"WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"+ WORKTRUNK_TEST_FISH_INSTALLED: "0"+ WORKTRUNK_TEST_GEMINI_INSTALLED: "0"WORKTRUNK_TEST_NUSHELL_ENV: "0"WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"+ WORKTRUNK_TEST_POWERSHELL_INSTALLED: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"+ WORKTRUNK_TEST_ZSH_INSTALLED: "0"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"---success: true@@ -48,6 +60,8 @@ exit_code: 0execute still runs----- stderr -----+[33m▲[39m [33m[1m--execute[22m will change in a future release: it will run a single program, with arguments after [1m--[22m, not a shell command line[39m+[2m↳[22m [2mTo run this command line unchanged, pass it to a shell: [4m--execute sh -- -c 'echo '\''execute still runs'\'''[24m[22m[33m▲[39m [33mWorktree for [1mexisting-no-hooks[22m @ [1m_REPO_.existing-no-hooks[22m, but cannot change directory — shell integration not installed[39m[2m↳[22m [2mTo enable automatic cd, run [4mwt config shell install[24m[22m[36m◎[39m [36mExecuting (--execute) @ [1m_REPO_.existing-no-hooks[22m:[39m