Skip to content

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

Reduce error message spacing from double to single newline

Maximilian Roos338baff3bc2e
diff --git a/src/git/error.rs b/src/git/error.rs
index 8ef2a5eaa..744976027 100644
--- a/src/git/error.rs
+++ b/src/git/error.rs
@@ -148,7 +148,7 @@ impl std::fmt::Display for GitError {
};
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message(&message),
hint_message(cformat!(
"To switch to a branch, run <bright-black>git switch <<branch>></>"
@@ -171,7 +171,7 @@ impl std::fmt::Display for GitError {
};
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message(&message),
hint_message("Commit or stash changes first")
)
@@ -181,7 +181,7 @@ impl std::fmt::Display for GitError {
let switch_cmd = suggest_command("switch", &[branch], &[]);
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message(cformat!("Branch <bold>{branch}</> already exists")),
hint_message(cformat!(
"To switch to the existing branch, remove <bright-black>--create</>; run <bright-black>{switch_cmd}</>"
@@ -194,7 +194,7 @@ impl std::fmt::Display for GitError {
let list_cmd = suggest_command("list", &[], &["--branches", "--remotes"]);
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message(cformat!("Branch <bold>{reference}</> not found")),
hint_message(cformat!(
"To create a new branch, run <bright-black>{create_cmd}</>; to list branches, run <bright-black>{list_cmd}</>"
@@ -205,7 +205,7 @@ impl std::fmt::Display for GitError {
GitError::WorktreeMissing { branch } => {
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message(cformat!("Worktree directory missing for <bold>{branch}</>")),
hint_message(cformat!(
"To clean up, run <bright-black>git worktree prune</>"
@@ -225,7 +225,7 @@ impl std::fmt::Display for GitError {
let cmd = suggest_command("switch", &[branch], &[]);
cwrite!(
f,
- "{ERROR_SYMBOL} <red>Branch <bold>{branch}</> exists only on remote ({remote}/{branch})</>\n\n{HINT_SYMBOL} <dim>To create a local worktree, run <bright-black>{cmd}</></>"
+ "{ERROR_SYMBOL} <red>Branch <bold>{branch}</> exists only on remote ({remote}/{branch})</>\n{HINT_SYMBOL} <dim>To create a local worktree, run <bright-black>{cmd}</></>"
)
}
@@ -248,7 +248,7 @@ impl std::fmt::Display for GitError {
let command = format!("cd {path_escaped} && git switch {branch}");
write!(
f,
- "{}\n\n{}\n{}",
+ "{}\n{}\n{}",
error_message(cformat!(
"Cannot create worktree for <bold>{branch}</>: {error_detail}"
)),
@@ -273,7 +273,7 @@ impl std::fmt::Display for GitError {
let switch_cmd = suggest_command("switch", &[branch], flags);
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message(cformat!(
"Directory already exists: <bold>{path_display}</>"
)),
@@ -395,7 +395,7 @@ impl std::fmt::Display for GitError {
} else {
write!(
f,
- "\n\n{}\n{}",
+ "\n{}\n{}",
hint_message(cformat!(
"To continue after resolving conflicts, run <bright-black>git rebase --continue</>"
)),
@@ -410,7 +410,7 @@ impl std::fmt::Display for GitError {
let rebase_cmd = suggest_command("step", &["rebase", target_branch], &[]);
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message(cformat!("Branch not rebased onto <bold>{target_branch}</>")),
hint_message(cformat!(
"Remove <bright-black>--no-rebase</>; or to rebase first, run <bright-black>{rebase_cmd}</>"
@@ -432,7 +432,7 @@ impl std::fmt::Display for GitError {
let approvals_cmd = suggest_command("hook", &["approvals", "add"], &[]);
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message("Cannot prompt for approval in non-interactive environment"),
hint_message(cformat!(
"To skip prompts in CI/CD, add <bright-black>--force</>; to pre-approve commands, run <bright-black>{approvals_cmd}</>"
@@ -477,7 +477,7 @@ impl std::fmt::Display for GitError {
let command_gutter = format_with_gutter(display_command, None);
write!(
f,
- "{}\n\n{}\n{}",
+ "{}\n{}\n{}",
error_block.trim_end(),
info_message("Ran command:"),
command_gutter.trim_end()
@@ -488,7 +488,7 @@ impl std::fmt::Display for GitError {
let path_display = format_path_for_display(config_path);
write!(
f,
- "{}\n\n{}",
+ "{}\n{}",
error_message("No project configuration found"),
hint_message(cformat!("Create a config file at: <bold>{path_display}</>"))
)
@@ -628,7 +628,7 @@ impl std::fmt::Display for HookErrorWithHint {
// Can't derive command from hook type (e.g., PreRemove is used by both `wt remove` and `wt merge`)
write!(
f,
- "\n\n{}",
+ "\n{}",
hint_message(cformat!(
"To skip {} hooks, re-run with <bright-black>--no-verify</>",
self.hook_type
@@ -662,9 +662,8 @@ mod tests {
#[test]
fn snapshot_detached_head_display() {
let err = GitError::DetachedHead { action: None };
- assert_snapshot!(err.to_string(), @r"
+ assert_snapshot!(err.to_string(), @"
✗ Not on a branch (detached HEAD)
-
↳ To switch to a branch, run git switch <branch>
");
}
@@ -675,9 +674,8 @@ mod tests {
action: Some("merge".into()),
worktree: Some("wt".into()),
};
- assert_snapshot!(err.to_string(), @r"
+ assert_snapshot!(err.to_string(), @"
✗ Cannot merge: wt has uncommitted changes
-
↳ Commit or stash changes first
");
}
@@ -691,9 +689,8 @@ mod tests {
.into();
let downcast = err.downcast_ref::<GitError>().expect("Should downcast");
- assert_snapshot!(downcast.to_string(), @r"
+ assert_snapshot!(downcast.to_string(), @"
✗ Branch main already exists
-
↳ To switch to the existing branch, remove --create; run wt switch main
");
}
@@ -721,7 +718,6 @@ mod tests {
};
assert_snapshot!(err.to_string(), @"
✗ Directory already exists: /some/path
-
↳ To remove manually, run rm -rf /some/path; to overwrite (with backup), run wt switch feature --clobber
");
}
@@ -735,7 +731,6 @@ mod tests {
};
assert_snapshot!(err.to_string(), @"
✗ Directory already exists: /some/path
-
↳ To remove manually, run rm -rf /some/path; to overwrite (with backup), run wt switch feature --create --clobber
");
}
diff --git a/tests/integration_tests/merge.rs b/tests/integration_tests/merge.rs
index c74065db3..613b6621c 100644
--- a/tests/integration_tests/merge.rs
+++ b/tests/integration_tests/merge.rs
@@ -1683,7 +1683,6 @@ fn test_merge_no_commit_with_dirty_tree(mut repo: TestRepo) {
----- stderr -----
✗ Cannot merge with --no-commit: feature has uncommitted changes
-
↳ Commit or stash changes first
");
});
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__branch_already_exists.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__branch_already_exists.snap
index 2389b9a8b..763b9131a 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__branch_already_exists.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__branch_already_exists.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Branch feature already exists
-
↳ To switch to the existing branch, remove --create; run wt switch feature
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head.snap
index 63da255b6..841431f6d 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Cannot merge: not on a branch (detached HEAD)
-
↳ To switch to a branch, run git switch <branch>
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head_no_action.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head_no_action.snap
index 510fe705e..b5d173254 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head_no_action.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__detached_head_no_action.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Not on a branch (detached HEAD)
-
↳ To switch to a branch, run git switch <branch>
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__hook_command_failed_with_skip_hint.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__hook_command_failed_with_skip_hint.snap
index 4c1b64af3..786f73a11 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__hook_command_failed_with_skip_hint.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__hook_command_failed_with_skip_hint.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err_with_hint.to_string()
---
✗ pre-merge command failed: test: exit code 1
-
↳ To skip pre-merge hooks, re-run with --no-verify
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__invalid_reference.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__invalid_reference.snap
index 662dd6f9c..ab420d92a 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__invalid_reference.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__invalid_reference.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Branch nonexistent-branch not found
-
↳ To create a new branch, run wt switch nonexistent-branch --create; to list branches, run wt list --branches --remotes
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed.snap
index 1b12a21e1..8bc7ab348 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed.snap
@@ -4,6 +4,5 @@ expression: err.to_string()
---
✗ Commit generation command failed
  Error: API key not found
-
○ Ran command:
  llm --model claude
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed_with_reproduction.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed_with_reproduction.snap
index 596b0555d..14e8f1375 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed_with_reproduction.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__llm_command_failed_with_reproduction.snap
@@ -4,6 +4,5 @@ expression: err.to_string()
---
✗ Commit generation command failed
  Error: API key not found
-
○ Ran command:
  wt step commit --show-prompt | llm --model claude
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__not_interactive.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__not_interactive.snap
index 2cc7c081c..623a5f6c2 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__not_interactive.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__not_interactive.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__project_config_not_found.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__project_config_not_found.snap
index 75f86bc65..aef6b86db 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__project_config_not_found.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__project_config_not_found.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ No project configuration found
-
↳ Create a config file at: /tmp/repo/.config/wt.toml
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__remote_only_branch.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__remote_only_branch.snap
index c342b75ca..4c5a5d626 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__remote_only_branch.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__remote_only_branch.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Branch feature exists only on remote (origin/feature)
-
↳ To create a local worktree, run wt switch feature
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes.snap
index cdfef5602..7b750f3c7 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Cannot remove worktree: working tree has uncommitted changes
-
↳ Commit or stash changes first
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes_with_worktree.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes_with_worktree.snap
index 325594baa..18dd8d75b 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes_with_worktree.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__uncommitted_changes_with_worktree.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Cannot remove worktree: feature-branch has uncommitted changes
-
↳ Commit or stash changes first
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_missing.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_missing.snap
index 1ac98e844..fe24c3dd2 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_missing.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_missing.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Worktree directory missing for stale-branch
-
↳ To clean up, run git worktree prune
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_exists.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_exists.snap
index 9fa8791d5..bfdc909e6 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_exists.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_exists.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Directory already exists: /tmp/repo.feature
-
↳ To remove manually, run rm -rf /tmp/repo.feature; to overwrite (with backup), run wt switch feature --clobber
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_occupied.snap b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_occupied.snap
index 2fa335057..a2466fcfe 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_occupied.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__git_error_display__worktree_path_occupied.snap
@@ -3,6 +3,5 @@ source: tests/integration_tests/git_error_display.rs
expression: err.to_string()
---
✗ Cannot create worktree for feature-z: existing worktree at /tmp/repo.feature-z on other-branch
-
↳ To switch the worktree to this branch:
  cd /tmp/repo.feature-z && git switch feature-z
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__command_failure.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__command_failure.snap
index ffe3f5383..ff6b4768a 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__command_failure.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__command_failure.snap
@@ -3,5 +3,4 @@ source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized()
---
✗ Branch existing already exists
-
↳ To switch to the existing branch, remove --create; run wt switch existing
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_bash.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_bash.snap
index 9cda0dfd0..33cbb61f3 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_bash.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_bash.snap
@@ -9,5 +9,4 @@ expression: output.normalized()
  echo '✗ Test suite failed: 3 tests failing' && exit 1
✗ Test suite failed: 3 tests failing
✗ pre-merge command failed: test: exit status: 1
-
↳ To skip pre-merge hooks, re-run with --no-verify
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_zsh.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_zsh.snap
index 9cda0dfd0..33cbb61f3 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_zsh.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_zsh.snap
@@ -9,5 +9,4 @@ expression: output.normalized()
  echo '✗ Test suite failed: 3 tests failing' && exit 1
✗ Test suite failed: 3 tests failing
✗ pre-merge command failed: test: exit status: 1
-
↳ To skip pre-merge hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__approval_fails_in_non_tty.snap b/tests/snapshots/integration__integration_tests__approval_ui__approval_fails_in_non_tty.snap
index 8f98dadfd..95bee02a5 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__approval_fails_in_non_tty.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__approval_fails_in_non_tty.snap
@@ -36,5 +36,4 @@ exit_code: 1
○ post-create:
  echo 'test command'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__approval_mixed_approved_unapproved.snap b/tests/snapshots/integration__integration_tests__approval_ui__approval_mixed_approved_unapproved.snap
index 804082950..d31133c40 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__approval_mixed_approved_unapproved.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__approval_mixed_approved_unapproved.snap
@@ -13,5 +13,4 @@ exit_code: 1
○ post-create third:
  echo 'Third command'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__approval_multiple_commands.snap b/tests/snapshots/integration__integration_tests__approval_ui__approval_multiple_commands.snap
index 0fca8d96a..a1e9eb215 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__approval_multiple_commands.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__approval_multiple_commands.snap
@@ -17,5 +17,4 @@ exit_code: 1
○ post-create pwd:
  cd {{ worktree }} && pwd
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__approval_named_commands.snap b/tests/snapshots/integration__integration_tests__approval_ui__approval_named_commands.snap
index 317597c10..b631b0686 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__approval_named_commands.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__approval_named_commands.snap
@@ -15,5 +15,4 @@ exit_code: 1
○ post-create test:
  echo 'Running tests...'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__approval_single_command.snap b/tests/snapshots/integration__integration_tests__approval_ui__approval_single_command.snap
index 264b2f9c7..d3f73882c 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__approval_single_command.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__approval_single_command.snap
@@ -11,5 +11,4 @@ exit_code: 1
○ post-create:
  echo 'Worktree path: {{ worktree }}'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__decline_approval_skips_only_unapproved.snap b/tests/snapshots/integration__integration_tests__approval_ui__decline_approval_skips_only_unapproved.snap
index 804082950..d31133c40 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__decline_approval_skips_only_unapproved.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__decline_approval_skips_only_unapproved.snap
@@ -13,5 +13,4 @@ exit_code: 1
○ post-create third:
  echo 'Third command'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__force_does_not_save_approvals_second_run.snap b/tests/snapshots/integration__integration_tests__approval_ui__force_does_not_save_approvals_second_run.snap
index 68f32a04f..5103f5917 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__force_does_not_save_approvals_second_run.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__force_does_not_save_approvals_second_run.snap
@@ -11,5 +11,4 @@ exit_code: 1
○ post-create:
  echo 'test command' > output.txt
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__run_hook_post_merge_requires_approval.snap b/tests/snapshots/integration__integration_tests__approval_ui__run_hook_post_merge_requires_approval.snap
index d488b934a..f246d7583 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__run_hook_post_merge_requires_approval.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__run_hook_post_merge_requires_approval.snap
@@ -11,5 +11,4 @@ exit_code: 1
○ post-merge:
  echo 'Post-merge cleanup for {{ branch }}'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approval_ui__run_hook_pre_merge_requires_approval.snap b/tests/snapshots/integration__integration_tests__approval_ui__run_hook_pre_merge_requires_approval.snap
index 50ef6d426..c6f3f14de 100644
--- a/tests/snapshots/integration__integration_tests__approval_ui__run_hook_pre_merge_requires_approval.snap
+++ b/tests/snapshots/integration__integration_tests__approval_ui__run_hook_pre_merge_requires_approval.snap
@@ -11,5 +11,4 @@ exit_code: 1
○ pre-merge:
  echo 'Running pre-merge checks on {{ branch }}'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_already_approved.snap b/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_already_approved.snap
index ac37e4646..b1edd57fd 100644
--- a/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_already_approved.snap
+++ b/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_already_approved.snap
@@ -36,5 +36,4 @@ exit_code: 1
○ post-create:
  echo 'test'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_none_approved.snap b/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_none_approved.snap
index 364ed1c04..a4bc0bc4c 100644
--- a/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_none_approved.snap
+++ b/tests/snapshots/integration__integration_tests__approvals__add_approvals_all_none_approved.snap
@@ -37,5 +37,4 @@ exit_code: 1
○ post-create:
  echo 'test'
✗ Cannot prompt for approval in non-interactive environment
-
↳ To skip prompts in CI/CD, add --force; to pre-approve commands, run wt hook approvals add
diff --git a/tests/snapshots/integration__integration_tests__approvals__add_approvals_no_config.snap b/tests/snapshots/integration__integration_tests__approvals__add_approvals_no_config.snap
index d1a5ed7cb..8c49f46c8 100644
--- a/tests/snapshots/integration__integration_tests__approvals__add_approvals_no_config.snap
+++ b/tests/snapshots/integration__integration_tests__approvals__add_approvals_no_config.snap
@@ -32,5 +32,4 @@ exit_code: 1
----- stderr -----
✗ No project configuration found
-
↳ Create a config file at: _REPO_/.config/wt.toml
diff --git a/tests/snapshots/integration__integration_tests__config_show__config_show_full_command_not_found.snap b/tests/snapshots/integration__integration_tests__config_show__config_show_full_command_not_found.snap
index 88d9f2ca8..c9494a117 100644
--- a/tests/snapshots/integration__integration_tests__config_show__config_show_full_command_not_found.snap
+++ b/tests/snapshots/integration__integration_tests__config_show__config_show_full_command_not_found.snap
@@ -51,6 +51,5 @@ exit_code: 0
✗ Commit generation failed (nonexistent-llm-command-12345 -m test-model)
  ✗ Commit generation command failed
    Failed to spawn LLM command
- 
  ○ Ran command:
    nonexistent-llm-command-12345 -m test-model
diff --git a/tests/snapshots/integration__integration_tests__directives__switch_without_directive_file.snap b/tests/snapshots/integration__integration_tests__directives__switch_without_directive_file.snap
index dc1216601..aab038ee4 100644
--- a/tests/snapshots/integration__integration_tests__directives__switch_without_directive_file.snap
+++ b/tests/snapshots/integration__integration_tests__directives__switch_without_directive_file.snap
@@ -31,5 +31,4 @@ exit_code: 1
----- stderr -----
✗ Branch my-feature not found
-
↳ To create a new branch, run wt switch my-feature --create; to list branches, run wt list --branches --remotes
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_error_detached_head.snap b/tests/snapshots/integration__integration_tests__merge__merge_error_detached_head.snap
index bbe419474..52217fee0 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_error_detached_head.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_error_detached_head.snap
@@ -31,5 +31,4 @@ exit_code: 1
----- stderr -----
✗ Cannot merge: not on a branch (detached HEAD)
-
↳ To switch to a branch, run git switch <branch>
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_error_uncommitted_changes_no_commit.snap b/tests/snapshots/integration__integration_tests__merge__merge_error_uncommitted_changes_no_commit.snap
index 5b227932e..b6087f0d6 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_error_uncommitted_changes_no_commit.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_error_uncommitted_changes_no_commit.snap
@@ -33,5 +33,4 @@ exit_code: 1
----- stderr -----
✗ Cannot merge with --no-commit: feature has uncommitted changes
-
↳ Commit or stash changes first
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_no_rebase_not_rebased.snap b/tests/snapshots/integration__integration_tests__merge__merge_no_rebase_not_rebased.snap
index 05a7df60f..5ed109cad 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_no_rebase_not_rebased.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_no_rebase_not_rebased.snap
@@ -32,5 +32,4 @@ exit_code: 1
----- stderr -----
✗ Branch not rebased onto main
-
↳ Remove --no-rebase; or to rebase first, run wt step rebase main
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snap b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snap
index 44c0c3ddd..22612799b 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snap
@@ -42,5 +42,4 @@ exit_code: 1
  exit 1
▲ Command failed: exit status: 1
✗ post-merge command failed: exit status: 1
-
↳ To skip post-merge hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_pre_commit_command_failure.snap b/tests/snapshots/integration__integration_tests__merge__merge_pre_commit_command_failure.snap
index 8069e32c4..c76af18fa 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_pre_commit_command_failure.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_pre_commit_command_failure.snap
@@ -36,5 +36,4 @@ exit_code: 1
◎ Running project pre-commit:
  exit 1
✗ pre-commit command failed: exit status: 1
-
↳ To skip pre-commit hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_failure.snap b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_failure.snap
index 663d7c47c..e5515d54c 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_failure.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_failure.snap
@@ -34,5 +34,4 @@ exit_code: 1
◎ Running project pre-merge:
  exit 1
✗ pre-merge command failed: exit status: 1
-
↳ To skip pre-merge hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_pre_squash_command_failure.snap b/tests/snapshots/integration__integration_tests__merge__merge_pre_squash_command_failure.snap
index 82ce3be4f..1f577a8e7 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_pre_squash_command_failure.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_pre_squash_command_failure.snap
@@ -34,5 +34,4 @@ exit_code: 1
◎ Running project pre-commit:
  exit 1
✗ pre-commit command failed: exit status: 1
-
↳ To skip pre-commit hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_command_not_found.snap b/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_command_not_found.snap
index 70d450c74..30aa153d0 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_command_not_found.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_command_not_found.snap
@@ -35,6 +35,5 @@ exit_code: 1
◎ Generating squash commit message...
✗ Commit generation command failed
  Failed to spawn LLM command
-
○ Ran command:
  wt step squash --show-prompt | nonexistent-llm-command
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_error.snap b/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_error.snap
index 19ebfe06b..6e50c61ff 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_error.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_squash_llm_error.snap
@@ -34,6 +34,5 @@ exit_code: 1
◎ Generating squash commit message...
✗ Commit generation command failed
  Error: connection refused
-
○ Ran command:
  wt step squash --show-prompt | sh -c cat > /dev/null; echo 'Error: connection refused' >&2 && exit 1
diff --git a/tests/snapshots/integration__integration_tests__remove__pre_remove_hook_failure_aborts.snap b/tests/snapshots/integration__integration_tests__remove__pre_remove_hook_failure_aborts.snap
index d860b081b..0a35fe14d 100644
--- a/tests/snapshots/integration__integration_tests__remove__pre_remove_hook_failure_aborts.snap
+++ b/tests/snapshots/integration__integration_tests__remove__pre_remove_hook_failure_aborts.snap
@@ -35,5 +35,4 @@ exit_code: 1
◎ Running project pre-remove:
  exit 1
✗ pre-remove command failed: exit status: 1
-
↳ To skip pre-remove hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__remove__remove_by_name_dirty_target.snap b/tests/snapshots/integration__integration_tests__remove__remove_by_name_dirty_target.snap
index 3019ab140..f93618ced 100644
--- a/tests/snapshots/integration__integration_tests__remove__remove_by_name_dirty_target.snap
+++ b/tests/snapshots/integration__integration_tests__remove__remove_by_name_dirty_target.snap
@@ -31,5 +31,4 @@ exit_code: 1
----- stderr -----
✗ Cannot remove worktree: feature-dirty has uncommitted changes
-
↳ Commit or stash changes first
diff --git a/tests/snapshots/integration__integration_tests__remove__remove_remote_only_branch.snap b/tests/snapshots/integration__integration_tests__remove__remove_remote_only_branch.snap
index ffc37de37..dd0fac374 100644
--- a/tests/snapshots/integration__integration_tests__remove__remove_remote_only_branch.snap
+++ b/tests/snapshots/integration__integration_tests__remove__remove_remote_only_branch.snap
@@ -31,5 +31,4 @@ exit_code: 1
----- stderr -----
✗ Branch remote-feature exists only on remote (origin/remote-feature)
-
↳ To create a local worktree, run wt switch remote-feature
diff --git a/tests/snapshots/integration__integration_tests__security__branch_name_with_cd_directive_not_executed.snap b/tests/snapshots/integration__integration_tests__security__branch_name_with_cd_directive_not_executed.snap
index 1b65415e0..be3658896 100644
--- a/tests/snapshots/integration__integration_tests__security__branch_name_with_cd_directive_not_executed.snap
+++ b/tests/snapshots/integration__integration_tests__security__branch_name_with_cd_directive_not_executed.snap
@@ -24,7 +24,7 @@ info:
SOURCE_DATE_EPOCH: "1735776000"
USERPROFILE: "[TEST_HOME]"
WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"
- WORKTRUNK_DIRECTIVE_FILE: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpkyUIH2
+ WORKTRUNK_DIRECTIVE_FILE: "[DIRECTIVE_FILE]"
XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"
---
success: false
@@ -33,5 +33,4 @@ exit_code: 1
----- stderr -----
✗ Branch __WORKTRUNK_CD__/tmp already exists
-
↳ To switch to the existing branch, remove --create; run wt switch __WORKTRUNK_CD__/tmp
diff --git a/tests/snapshots/integration__integration_tests__security__error_message_with_directive_not_executed.snap b/tests/snapshots/integration__integration_tests__security__error_message_with_directive_not_executed.snap
index acc23049e..7081032bb 100644
--- a/tests/snapshots/integration__integration_tests__security__error_message_with_directive_not_executed.snap
+++ b/tests/snapshots/integration__integration_tests__security__error_message_with_directive_not_executed.snap
@@ -23,7 +23,7 @@ info:
SOURCE_DATE_EPOCH: "1735776000"
USERPROFILE: "[TEST_HOME]"
WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"
- WORKTRUNK_DIRECTIVE_FILE: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpMhB5Xq
+ WORKTRUNK_DIRECTIVE_FILE: "[DIRECTIVE_FILE]"
XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"
---
success: false
@@ -32,5 +32,4 @@ exit_code: 1
----- stderr -----
✗ Branch __WORKTRUNK_EXEC__echo PWNED > /tmp/hacked6 not found
-
↳ To create a new branch, run wt switch '__WORKTRUNK_EXEC__echo PWNED > /tmp/hacked6' --create; to list branches, run wt list --branches --remotes
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_create_existing_error.snap b/tests/snapshots/integration__integration_tests__switch__switch_create_existing_error.snap
index f436adb95..90c83278d 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_create_existing_error.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_create_existing_error.snap
@@ -32,5 +32,4 @@ exit_code: 1
----- stderr -----
✗ Branch feature-y already exists
-
↳ To switch to the existing branch, remove --create; run wt switch feature-y
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_error_main_worktree_on_different_branch.snap b/tests/snapshots/integration__integration_tests__switch__switch_error_main_worktree_on_different_branch.snap
index a277a7c46..8b491265b 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_error_main_worktree_on_different_branch.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_error_main_worktree_on_different_branch.snap
@@ -23,7 +23,7 @@ info:
SOURCE_DATE_EPOCH: "1735776000"
USERPROFILE: "[TEST_HOME]"
WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"
- WORKTRUNK_DIRECTIVE_FILE: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp2rkJvk
+ WORKTRUNK_DIRECTIVE_FILE: "[DIRECTIVE_FILE]"
XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"
---
success: false
@@ -32,6 +32,5 @@ exit_code: 1
----- stderr -----
✗ Cannot create worktree for main: existing worktree at _REPO_ on feature
-
↳ To switch the worktree to this branch:
  cd _REPO_ && git switch main
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_error_missing_directory.snap b/tests/snapshots/integration__integration_tests__switch__switch_error_missing_directory.snap
index 88a0d96c8..e64e76049 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_error_missing_directory.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_error_missing_directory.snap
@@ -31,5 +31,4 @@ exit_code: 1
----- stderr -----
✗ Worktree directory missing for missing-wt
-
↳ To clean up, run git worktree prune
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied.snap b/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied.snap
index 5af84e08d..0e886493a 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied.snap
@@ -32,5 +32,4 @@ exit_code: 1
----- stderr -----
✗ Directory already exists: _REPO_.occupied-branch
-
↳ To remove manually, run rm -rf _REPO_.occupied-branch; to overwrite (with backup), run wt switch occupied-branch --create --clobber
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_detached.snap b/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_detached.snap
index c5805befd..673e188a4 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_detached.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_detached.snap
@@ -23,7 +23,7 @@ info:
SOURCE_DATE_EPOCH: "1735776000"
USERPROFILE: "[TEST_HOME]"
WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"
- WORKTRUNK_DIRECTIVE_FILE: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpGK1tDz
+ WORKTRUNK_DIRECTIVE_FILE: "[DIRECTIVE_FILE]"
XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"
---
success: false
@@ -32,6 +32,5 @@ exit_code: 1
----- stderr -----
✗ Cannot create worktree for feature: existing worktree at _REPO_.feature, detached
-
↳ To switch the worktree to this branch:
  cd _REPO_.feature && git switch feature
diff --git a/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_different_branch.snap b/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_different_branch.snap
index be6f89195..c99ef9c0d 100644
--- a/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_different_branch.snap
+++ b/tests/snapshots/integration__integration_tests__switch__switch_error_path_occupied_different_branch.snap
@@ -23,7 +23,7 @@ info:
SOURCE_DATE_EPOCH: "1735776000"
USERPROFILE: "[TEST_HOME]"
WORKTRUNK_CONFIG_PATH: "[TEST_CONFIG]"
- WORKTRUNK_DIRECTIVE_FILE: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpLxHMDw
+ WORKTRUNK_DIRECTIVE_FILE: "[DIRECTIVE_FILE]"
XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"
---
success: false
@@ -32,6 +32,5 @@ exit_code: 1
----- stderr -----
✗ Cannot create worktree for feature: existing worktree at _REPO_.feature on bugfix
-
↳ To switch the worktree to this branch:
  cd _REPO_.feature && git switch feature
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_pre_commit_failure.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_pre_commit_failure.snap
index b1352d119..7ddca0c8b 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_pre_commit_failure.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_pre_commit_failure.snap
@@ -37,5 +37,4 @@ exit_code: 1
◎ Running user pre-commit lint:
  exit 1
✗ pre-commit command failed: lint: exit status: 1
-
↳ To skip pre-commit hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_pre_merge_failure.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_pre_merge_failure.snap
index da687b426..a2b958452 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_pre_merge_failure.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_pre_merge_failure.snap
@@ -35,5 +35,4 @@ exit_code: 1
◎ Running user pre-merge check:
  exit 1
✗ pre-merge command failed: check: exit status: 1
-
↳ To skip pre-merge hooks, re-run with --no-verify
diff --git a/tests/snapshots/integration__integration_tests__user_hooks__user_pre_remove_failure.snap b/tests/snapshots/integration__integration_tests__user_hooks__user_pre_remove_failure.snap
index f2000d501..a784b6d4a 100644
--- a/tests/snapshots/integration__integration_tests__user_hooks__user_pre_remove_failure.snap
+++ b/tests/snapshots/integration__integration_tests__user_hooks__user_pre_remove_failure.snap
@@ -34,5 +34,4 @@ exit_code: 1
◎ Running user pre-remove block:
  exit 1
✗ pre-remove command failed: block: exit status: 1
-
↳ To skip pre-remove hooks, re-run with --no-verify