Skip to content

Worktrunk is a CLI for Git worktree management, designed for parallel AI agent workflows

feat: show git progress for slow worktree creation (#725)

Maximilian Roos6e11b5b6e14b
diff --git a/src/commands/worktree/switch.rs b/src/commands/worktree/switch.rs
index e71cb2bba..cb9a883ef 100644
--- a/src/commands/worktree/switch.rs
+++ b/src/commands/worktree/switch.rs
@@ -309,14 +309,20 @@ fn setup_fork_pr_branch(
repo.run_command(&["config", &branch_push_remote_key, fork_push_url])
.with_context(|| format!("Failed to configure branch.{}.pushRemote", branch))?;
- // Create worktree
+ // Create worktree (delayed streaming: silent if fast, shows progress if slow)
let worktree_path_str = worktree_path.to_string_lossy();
- repo.run_command(&["worktree", "add", worktree_path_str.as_ref(), branch])
- .map_err(|e| GitError::WorktreeCreationFailed {
- branch: branch.to_string(),
- base_branch: None,
- error: e.to_string(),
- })?;
+ repo.run_command_delayed_stream(
+ &["worktree", "add", worktree_path_str.as_ref(), branch],
+ Repository::SLOW_OPERATION_DELAY_MS,
+ Some(
+ progress_message(cformat!("Creating worktree for <bold>{}</>...", branch)).to_string(),
+ ),
+ )
+ .map_err(|e| GitError::WorktreeCreationFailed {
+ branch: branch.to_string(),
+ base_branch: None,
+ error: e.to_string(),
+ })?;
Ok(())
}
@@ -467,7 +473,16 @@ pub fn execute_switch(
args.push(&branch);
}
- if let Err(e) = repo.run_command(&args) {
+ // Delayed streaming: silent if fast, shows progress if slow
+ let progress_msg = Some(
+ progress_message(cformat!("Creating worktree for <bold>{}</>...", branch))
+ .to_string(),
+ );
+ if let Err(e) = repo.run_command_delayed_stream(
+ &args,
+ Repository::SLOW_OPERATION_DELAY_MS,
+ progress_msg,
+ ) {
return Err(GitError::WorktreeCreationFailed {
branch: branch.clone(),
base_branch: base_branch.clone(),
diff --git a/src/git/repository/mod.rs b/src/git/repository/mod.rs
index 92730aeb3..aba662e26 100644
--- a/src/git/repository/mod.rs
+++ b/src/git/repository/mod.rs
@@ -505,6 +505,142 @@ impl Repository {
Ok(self.run_command_output(args)?.status.success())
}
+ /// Delay before showing progress output for slow operations.
+ /// See .claude/rules/cli-output-formatting.md: "Progress messages apply only to slow operations (>400ms)"
+ pub const SLOW_OPERATION_DELAY_MS: u64 = 400;
+
+ /// Run a git command with delayed output streaming.
+ ///
+ /// Buffers output initially, then streams if the command takes longer than
+ /// `delay_ms`. This provides a quiet experience for fast operations while
+ /// still showing progress for slow ones (like `worktree add` on large repos).
+ ///
+ /// If `progress_message` is provided, it will be printed to stderr when
+ /// streaming starts (i.e., when the delay threshold is exceeded).
+ ///
+ /// All output (both stdout and stderr from the child) is sent to stderr
+ /// to keep stdout clean for commands like `wt switch`.
+ pub fn run_command_delayed_stream(
+ &self,
+ args: &[&str],
+ delay_ms: u64,
+ progress_message: Option<String>,
+ ) -> anyhow::Result<()> {
+ use std::io::{BufRead, BufReader, Write};
+ use std::process::Stdio;
+ use std::sync::Mutex;
+ use std::sync::atomic::{AtomicBool, Ordering};
+ use std::thread;
+ use std::time::{Duration, Instant};
+
+ // Allow tests to override delay threshold (e.g., 0 to force immediate streaming)
+ let delay_ms = std::env::var("WT_TEST_DELAYED_STREAM_MS")
+ .ok()
+ .and_then(|s| s.parse().ok())
+ .unwrap_or(delay_ms);
+
+ let cmd_str = format!("git {}", args.join(" "));
+ log::debug!(
+ "$ {} [{}] (delayed stream, {}ms)",
+ cmd_str,
+ self.logging_context(),
+ delay_ms
+ );
+
+ let mut child = std::process::Command::new("git")
+ .args(args)
+ .current_dir(&self.discovery_path)
+ .stdin(Stdio::null())
+ .stdout(Stdio::piped())
+ .stderr(Stdio::piped())
+ .env_remove(crate::shell_exec::DIRECTIVE_FILE_ENV_VAR)
+ .spawn()
+ .with_context(|| format!("Failed to spawn: {}", cmd_str))?;
+
+ let stdout = child.stdout.take().expect("stdout was piped");
+ let stderr = child.stderr.take().expect("stderr was piped");
+
+ // Shared state: when true, output streams directly; when false, buffers
+ let streaming = Arc::new(AtomicBool::new(false));
+ let buffer = Arc::new(Mutex::new(Vec::new()));
+
+ // Reader threads for stdout and stderr (both go to stderr)
+ let stdout_handle = {
+ let streaming = streaming.clone();
+ let buffer = buffer.clone();
+ thread::spawn(move || {
+ let reader = BufReader::new(stdout);
+ for line in reader.lines().map_while(Result::ok) {
+ if streaming.load(Ordering::Relaxed) {
+ let _ = writeln!(std::io::stderr(), "{}", line);
+ let _ = std::io::stderr().flush();
+ } else {
+ buffer.lock().unwrap().push(line);
+ }
+ }
+ })
+ };
+
+ let stderr_handle = {
+ let streaming = streaming.clone();
+ let buffer = buffer.clone();
+ thread::spawn(move || {
+ let reader = BufReader::new(stderr);
+ for line in reader.lines().map_while(Result::ok) {
+ if streaming.load(Ordering::Relaxed) {
+ let _ = writeln!(std::io::stderr(), "{}", line);
+ let _ = std::io::stderr().flush();
+ } else {
+ buffer.lock().unwrap().push(line);
+ }
+ }
+ })
+ };
+
+ let start = Instant::now();
+ let delay = Duration::from_millis(delay_ms);
+
+ loop {
+ match child.try_wait() {
+ Ok(Some(status)) => {
+ let _ = stdout_handle.join();
+ let _ = stderr_handle.join();
+
+ if status.success() {
+ return Ok(());
+ }
+ // Failed - return buffered output as error
+ let lines = buffer.lock().unwrap();
+ let exit_info = status
+ .code()
+ .map(|c| format!("exit code {c}"))
+ .unwrap_or_else(|| "killed by signal".to_string());
+ if lines.is_empty() {
+ bail!("{cmd_str} failed ({exit_info})");
+ } else {
+ bail!("{}\n({cmd_str} failed, {exit_info})", lines.join("\n"));
+ }
+ }
+ Ok(None) => {
+ // Still running - check if we should switch to streaming
+ if !streaming.load(Ordering::Relaxed) && start.elapsed() >= delay {
+ streaming.store(true, Ordering::Relaxed);
+
+ if let Some(ref msg) = progress_message {
+ let _ = writeln!(std::io::stderr(), "{}", msg);
+ }
+ for line in buffer.lock().unwrap().drain(..) {
+ let _ = writeln!(std::io::stderr(), "{}", line);
+ }
+ let _ = std::io::stderr().flush();
+ }
+ thread::sleep(Duration::from_millis(10));
+ }
+ Err(e) => bail!("Failed to wait for command: {}", e),
+ }
+ }
+ }
+
/// Run a git command and return the raw Output (for inspecting exit codes).
///
/// Use this when exit codes have semantic meaning beyond success/failure.
diff --git a/tests/integration_tests/switch.rs b/tests/integration_tests/switch.rs
index 268d5c382..76d9ecf35 100644
--- a/tests/integration_tests/switch.rs
+++ b/tests/integration_tests/switch.rs
@@ -61,6 +61,19 @@ fn test_switch_create_new_branch(repo: TestRepo) {
snapshot_switch("switch_create_new", &repo, &["--create", "feature-x"]);
}
+/// Test that delayed streaming shows progress message when threshold is 0.
+/// This exercises the streaming code path that normally only triggers for slow operations.
+#[rstest]
+fn test_switch_create_shows_progress_when_forced(repo: TestRepo) {
+ let settings = setup_snapshot_settings(&repo);
+ settings.bind(|| {
+ let mut cmd = make_snapshot_cmd(&repo, "switch", &["--create", "feature-progress"], None);
+ // Force immediate streaming by setting threshold to 0
+ cmd.env("WT_TEST_DELAYED_STREAM_MS", "0");
+ assert_cmd_snapshot!("switch_create_with_progress", cmd);
+ });
+}
+
#[rstest]
fn test_switch_create_existing_branch_error(mut repo: TestRepo) {
// Create a branch first
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__already_approved_skip_prompt.snap b/tests/snapshots/integration__integration_tests__approval_ui__already_approved_skip_prompt.snap
index 942a0a9c8..7699a5c25 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__already_approved_skip_prompt.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__already_approved_skip_prompt.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__yes_bypasses_tty_check.snap b/tests/snapshots/integration__integration_tests__approval_ui__yes_bypasses_tty_check.snap
index f9ce0a359..844d39dc7 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__yes_bypasses_tty_check.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__yes_bypasses_tty_check.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__yes_does_not_save_approvals_first_run.snap b/tests/snapshots/integration__integration_tests__approval_ui__yes_does_not_save_approvals_first_run.snap
index 125596db8..981434fcc 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__yes_does_not_save_approvals_first_run.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__yes_does_not_save_approvals_first_run.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__merge__readme_example_simple_switch.snap b/tests/snapshots/integration__integration_tests__merge__readme_example_simple_switch.snap
index d79ccca97..bc9e631a1 100644
--- a/tests/snapshots/integration__integration_tests__merge__readme_example_simple_switch.snap
+++ b/tests/snapshots/integration__integration_tests__merge__readme_example_simple_switch.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__both_create_and_start.snap b/tests/snapshots/integration__integration_tests__post_start_commands__both_create_and_start.snap
index 5c41cb4cf..1243e18c5 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__both_create_and_start.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__both_create_and_start.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_base_variables.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_base_variables.snap
index ebbe1aaa6..37fb3ef95 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_base_variables.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_base_variables.snap
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_default_branch_template.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_default_branch_template.snap
index f34f888af..9fb9db9e2 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_default_branch_template.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_default_branch_template.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_failing_command.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_failing_command.snap
index 222932fc0..affa28879 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_failing_command.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_failing_command.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_git_variables_template.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_git_variables_template.snap
index 49d00eda9..3a584f5ac 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_git_variables_template.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_git_variables_template.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiline_control_structure.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiline_control_structure.snap
index cf73a387b..d2ad9cb0a 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiline_control_structure.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiline_control_structure.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_named_commands.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_named_commands.snap
index 8499d8951..ceda2eadc 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_named_commands.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_named_commands.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_no_config.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_no_config.snap
index de0650354..558c6bcdf 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_no_config.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_no_config.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_single_command.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_single_command.snap
index 04f1d19d6..97d87d748 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_single_command.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_single_command.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_template_expansion.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_template_expansion.snap
index 2d30c20ff..326d1ff99 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_template_expansion.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_template_expansion.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_complex_shell.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_complex_shell.snap
index a52237e90..1b584b77d 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_complex_shell.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_complex_shell.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_create_with_command.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_create_with_command.snap
index 37724bad7..f21f16b07 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_create_with_command.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_create_with_command.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_invalid_command.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_invalid_command.snap
index 41fbc7d7c..51f6ca441 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_invalid_command.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_invalid_command.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_log_captures_output.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_log_captures_output.snap
index a54fca513..b1f41c2a6 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_log_captures_output.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_log_captures_output.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiline_with_newlines.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiline_with_newlines.snap
index 588518cd8..ffa1ff440 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiline_with_newlines.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiline_with_newlines.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiple_background.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiple_background.snap
index 97f3d902b..2d2087be5 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiple_background.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_multiple_background.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_separate_logs.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_separate_logs.snap
index 08567ff8c..b385851e0 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_separate_logs.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_separate_logs.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_single_background.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_single_background.snap
index 33af4802d..18b1a92e5 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_start_single_background.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_start_single_background.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__bash_shell_integration_hint_suppressed.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__bash_shell_integration_hint_suppressed.snap
index f89de3f49..95fa69e24 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__bash_shell_integration_hint_suppressed.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__bash_shell_integration_hint_suppressed.snap
@@ -2,5 +2,6 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch bash-test from main and worktree @ _REPO_.bash-test
↳ To customize worktree locations, run wt config create
diff --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.snap
index a3a6d8c44..d7b8eddec 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
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch fish-multiline from main and worktree @ _REPO_.fish-multiline
↳ To customize worktree locations, run wt config create
◎ Executing (--execute):
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_handles_empty_chunks.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_handles_empty_chunks.snap
index 69001e3e8..b7e1d02e3 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_handles_empty_chunks.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_handles_empty_chunks.snap
@@ -2,5 +2,6 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch fish-minimal from main and worktree @ _REPO_.fish-minimal
↳ To customize worktree locations, run wt config create
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_preserves_progress_messages.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_preserves_progress_messages.snap
index 91dd5fc83..7caf0cbb6 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_preserves_progress_messages.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__fish_wrapper_preserves_progress_messages.snap
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch fish-bg from main and worktree @ _REPO_.fish-bg
↳ To customize worktree locations, run wt config create
◎ Running post-start project hook:
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_hooks_post_create.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_hooks_post_create.snap
index 5802cd781..4c7292ef1 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_hooks_post_create.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_hooks_post_create.snap
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
◎ Running post-create project:install:
  uv sync
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_simple_switch.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_simple_switch.snap
index 3342fb64f..cefcb086d 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_simple_switch.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__readme_example_simple_switch.snap
@@ -2,5 +2,6 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch fix-auth from main and worktree @ _REPO_.fix-auth
↳ To customize worktree locations, run wt config create
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_create.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_create.snap
index a509263f0..da080aa4d 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_create.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_create.snap
@@ -2,5 +2,6 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch feature from main and worktree @ _REPO_.feature
↳ To customize worktree locations, run wt config create
diff --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.snap
index befe27829..9c1a08ec4 100644
--- 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.snap
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch test-exec from main and worktree @ _REPO_.test-exec
↳ To customize worktree locations, run wt config create
◎ Executing (--execute):
diff --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.snap
index befe27829..9c1a08ec4 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
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch test-exec from main and worktree @ _REPO_.test-exec
↳ To customize worktree locations, run wt config create
◎ Executing (--execute):
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_hooks_zsh.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_hooks_zsh.snap
index 914d80178..7aefcd02d 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_hooks_zsh.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_hooks_zsh.snap
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
◎ Running post-create project:install:
  echo 'Installing dependencies...'
Installing dependencies...
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_post_start_command_no_directive_leak.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_post_start_command_no_directive_leak.snap
index 2374bc038..5df19a2a5 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_post_start_command_no_directive_leak.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__switch_with_post_start_command_no_directive_leak.snap
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch feature-with-hooks from main and worktree @ _REPO_.feature-with-hooks
↳ To customize worktree locations, run wt config create
◎ Running post-start project hook:
diff --git a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__wrapper_preserves_progress_messages.snap b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__wrapper_preserves_progress_messages.snap
index 1fb574b4b..c855baab3 100644
--- a/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__wrapper_preserves_progress_messages.snap
+++ b/tests/snapshots/integration__integration_tests__shell_wrapper__unix_tests__wrapper_preserves_progress_messages.snap
@@ -2,6 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: "&output.combined"
---
+
✓ Created branch feature-bg from main and worktree @ _REPO_.feature-bg
↳ To customize worktree locations, run wt config create
◎ Running post-start project hook:
diff --git a/tests/snapshots/integration__integration_tests__switch__create_with_base_main.snap b/tests/snapshots/integration__integration_tests__switch__create_with_base_main.snap
index be7c4c15f..15e5b7404 100644
--- a/tests/snapshots/integration__integration_tests__switch__create_with_base_main.snap
+++ b/tests/snapshots/integration__integration_tests__switch__create_with_base_main.snap
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__ping_pong_1_main_to_feature.snap b/tests/snapshots/integration__integration_tests__switch__ping_pong_1_main_to_feature.snap
index 1e62f6234..001e5228e 100644
--- a/tests/snapshots/integration__integration_tests__switch__ping_pong_1_main_to_feature.snap
+++ b/tests/snapshots/integration__integration_tests__switch__ping_pong_1_main_to_feature.snap
@@ -13,6 +13,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_base_commitish_head.snap b/tests/snapshots/integration__integration_tests__switch__switch_base_commitish_head.snap
index d5aa65c7a..6329b09a8 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_base_commitish_head.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_base_commitish_head.snap
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_clobber_path_with_extension.snap b/tests/snapshots/integration__integration_tests__switch__switch_clobber_path_with_extension.snap
index 3e453d801..7cf8d23f3 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_clobber_path_with_extension.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_clobber_path_with_extension.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_dir.snap b/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_dir.snap
index c2251d695..7dc1c4ba8 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_dir.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_dir.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_file.snap b/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_file.snap
index 6955d24c1..4cf7139bb 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_file.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_clobber_removes_stale_file.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_create_new.snap b/tests/snapshots/integration__integration_tests__switch__switch_create_new.snap
index ba66aa04b..e1ea478e6 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_create_new.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_create_new.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_create_no_remote.snap b/tests/snapshots/integration__integration_tests__switch__switch_create_no_remote.snap
index 34ce54691..113fb3b64 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_create_no_remote.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_create_no_remote.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_create_remote_only.snap b/tests/snapshots/integration__integration_tests__switch__switch_create_remote_only.snap
index f9e5ce7bb..b2aaf0f24 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_create_remote_only.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_create_remote_only.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_create_with_progress.snap b/tests/snapshots/integration__integration_tests__switch__switch_create_with_progress.snap
new file mode 100644
index 000000000..6854e1156
--- /dev/null
+++ b/tests/snapshots/integration__integration_tests__switch__switch_create_with_progress.snap
@@ -0,0 +1,45 @@
+---
+source: tests/integration_tests/switch.rs
+info:
+ program: wt
+ args:
+ - switch
+ - "--create"
+ - feature-progress
+ 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_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
+ GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
+ GIT_TERMINAL_PROMPT: "0"
+ HOME: "[TEST_HOME]"
+ LANG: C
+ LC_ALL: C
+ MOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"
+ PATH: "[PATH]"
+ RUST_LOG: warn
+ SHELL: ""
+ SOURCE_DATE_EPOCH: "1735776000"
+ TERM: alacritty
+ USERPROFILE: "[TEST_HOME]"
+ WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"
+ WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"
+ WT_TEST_DELAYED_STREAM_MS: "0"
+ XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"
+---
+success: true
+exit_code: 0
+----- stdout -----
+
+----- stderr -----
+◎ Creating worktree for feature-progress...
+Preparing worktree (new branch 'feature-progress')
+HEAD is now at 05a4a45 Initial commit
+✓ Created branch feature-progress from main and worktree @ _REPO_.feature-progress
+↳ To customize worktree locations, run wt config create
+▲ Cannot change directory — shell integration not installed
+↳ To enable automatic cd, run wt config shell install
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_dwim_from_remote.snap b/tests/snapshots/integration__integration_tests__switch__switch_dwim_from_remote.snap
index d92c6f322..e588d1ed3 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_dwim_from_remote.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_dwim_from_remote.snap
@@ -13,6 +13,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_existing_local_with_upstream.snap b/tests/snapshots/integration__integration_tests__switch__switch_existing_local_with_upstream.snap
index ac7fd72a3..3422bccf8 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_existing_local_with_upstream.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_existing_local_with_upstream.snap
@@ -13,6 +13,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --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.snap
index d20724559..a6c0e68f4 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
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --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.snap
index 5206f699b..65311c3a0 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
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_internal_mode.snap b/tests/snapshots/integration__integration_tests__switch__switch_internal_mode.snap
index 619b95dcc..51703209b 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_internal_mode.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_internal_mode.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_internal_with_execute.snap b/tests/snapshots/integration__integration_tests__switch__switch_internal_with_execute.snap
index 0a1aabab3..8205cfb00 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
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_main_branch_to_feature.snap b/tests/snapshots/integration__integration_tests__switch__switch_main_branch_to_feature.snap
index a8aa572c8..21a28087b 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_main_branch_to_feature.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_main_branch_to_feature.snap
@@ -13,6 +13,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_skips_post_start.snap b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_skips_post_start.snap
index fdc259a5e..7c580c8e2 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_skips_post_start.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_skips_post_start.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_with_yes.snap b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_with_yes.snap
index c20a9e96b..9c2a05c25 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_with_yes.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_no_hooks_with_yes.snap
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_post_hook_no_path_with_shell_integration.snap b/tests/snapshots/integration__integration_tests__switch__switch_post_hook_no_path_with_shell_integration.snap
index b29ef46e2..d6cf7fe3b 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_post_hook_no_path_with_shell_integration.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_post_hook_no_path_with_shell_integration.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_post_hook_path_annotation.snap b/tests/snapshots/integration__integration_tests__switch__switch_post_hook_path_annotation.snap
index 570b52d00..4cb80c304 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_post_hook_path_annotation.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_post_hook_path_annotation.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_pr_fork.snap b/tests/snapshots/integration__integration_tests__switch__switch_pr_fork.snap
index 73367cebe..2d8ed389b 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_pr_fork.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_pr_fork.snap
@@ -13,6 +13,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_primary_on_different_branch.snap b/tests/snapshots/integration__integration_tests__switch__switch_primary_on_different_branch.snap
index e3647d138..897cda368 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_primary_on_different_branch.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_primary_on_different_branch.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_a.snap b/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_a.snap
index 7c80bae92..9a20716b0 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_a.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_a.snap
@@ -13,6 +13,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_b.snap b/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_b.snap
index 9b0851224..0899b5200 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_b.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_stale_history_to_b.snap
@@ -13,6 +13,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_with_base.snap b/tests/snapshots/integration__integration_tests__switch__switch_with_base.snap
index 4c3e4f74c..b82cc31c3 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_with_base.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_with_base.snap
@@ -16,6 +16,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__no_verify_skips_all_hooks.snap b/tests/snapshots/integration__integration_tests__user_hooks__no_verify_skips_all_hooks.snap
index 07a7ef12a..d5cf41779 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__no_verify_skips_all_hooks.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__no_verify_skips_all_hooks.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_and_project_post_start.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_and_project_post_start.snap
index 1fe6efa50..8961d09a4 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_and_project_post_start.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_and_project_post_start.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_hook_template_vars.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_hook_template_vars.snap
index 382bb6c63..cda671cc5 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_hook_template_vars.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_hook_template_vars.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_before_project.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_before_project.snap
index 8455a22d3..a38890029 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_before_project.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_before_project.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_no_approval.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_no_approval.snap
index 4b2612f53..d1158b83d 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_no_approval.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_hooks_no_approval.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_executes.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_executes.snap
index 4c32d08cb..ffb18fe4d 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_executes.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_executes.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_failure.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_failure.snap
index 1e7dfbe4a..23d57b1b9 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_failure.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_post_create_failure.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_executes.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_executes.snap
index fd31cabd3..9d1e51140 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_executes.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_executes.snap
@@ -14,6 +14,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_skipped_no_verify.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_skipped_no_verify.snap
index 07a7ef12a..d5cf41779 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_skipped_no_verify.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_post_start_skipped_no_verify.snap
@@ -15,6 +15,7 @@ info:
GIT_COMMITTER_DATE: "2025-01-01T00:00:00Z"
GIT_CONFIG_GLOBAL: "[TEST_GIT_CONFIG]"
GIT_CONFIG_SYSTEM: /dev/null
+ GIT_EDITOR: ""
GIT_TERMINAL_PROMPT: "0"
HOME: "[TEST_HOME]"
LANG: C