Skip to content

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

refactor(output): Standardize command execution progress messages

Maximilian Roos903608c96f01
diff --git a/src/commands/merge.rs b/src/commands/merge.rs
index f5764bdcb..bad595720 100644
--- a/src/commands/merge.rs
+++ b/src/commands/merge.rs
@@ -432,12 +432,8 @@ pub fn run_pre_merge_commands(
},
)?;
for prepared in commands {
- let header = if let Some(name) = &prepared.name {
- format!("πŸ”„ {CYAN}Running pre-merge command {CYAN_BOLD}{name}{CYAN_BOLD:#}:{CYAN:#}")
- } else {
- format!("πŸ”„ {CYAN}Running pre-merge command:{CYAN:#}")
- };
- crate::output::progress(header)?;
+ let label = crate::commands::format_command_label("pre-merge", prepared.name.as_deref());
+ crate::output::progress(format!("πŸ”„ {CYAN}{label}{CYAN:#}"))?;
crate::output::progress(format_bash_with_gutter(&prepared.expanded, ""))?;
if let Err(e) = execute_command_in_worktree(worktree_path, &prepared.expanded) {
@@ -502,12 +498,8 @@ pub fn execute_post_merge_commands(
// Execute each command sequentially in the main worktree
for prepared in commands {
- let header = if let Some(name) = &prepared.name {
- format!("πŸ”„ {CYAN}Running post-merge command {CYAN_BOLD}{name}{CYAN_BOLD:#}:{CYAN:#}")
- } else {
- format!("πŸ”„ {CYAN}Running post-merge command:{CYAN:#}")
- };
- crate::output::progress(header)?;
+ let label = crate::commands::format_command_label("post-merge", prepared.name.as_deref());
+ crate::output::progress(format!("πŸ”„ {CYAN}{label}{CYAN:#}"))?;
crate::output::progress(format_bash_with_gutter(&prepared.expanded, ""))?;
if let Err(e) = execute_command_in_worktree(main_worktree_path, &prepared.expanded) {
diff --git a/src/commands/mod.rs b/src/commands/mod.rs
index 5b8e5af88..5ab9aadf9 100644
--- a/src/commands/mod.rs
+++ b/src/commands/mod.rs
@@ -21,3 +21,15 @@ pub use worktree::{handle_push, handle_remove, handle_switch};
// Re-export Shell from the canonical location
pub use worktrunk::shell::Shell;
+
+/// Format command execution label with optional command name.
+///
+/// Examples:
+/// - `format_command_label("post-create", Some("install"))` β†’ `"Running post-create: install"`
+/// - `format_command_label("post-create", None)` β†’ `"Running post-create:"`
+pub fn format_command_label(command_type: &str, name: Option<&str>) -> String {
+ match name {
+ Some(name) => format!("Running {command_type}: {name}"),
+ None => format!("Running {command_type}:"),
+ }
+}
diff --git a/src/commands/worktree.rs b/src/commands/worktree.rs
index c6db0ad19..04cf339f7 100644
--- a/src/commands/worktree.rs
+++ b/src/commands/worktree.rs
@@ -430,7 +430,8 @@ pub fn execute_post_create_commands(
// Execute each command sequentially
for prepared in commands {
- crate::output::progress(format!("πŸ”„ {CYAN}Executing (post-create):{CYAN:#}"))?;
+ let label = crate::commands::format_command_label("post-create", prepared.name.as_deref());
+ crate::output::progress(format!("πŸ”„ {CYAN}{label}{CYAN:#}"))?;
crate::output::progress(format_bash_with_gutter(&prepared.expanded, ""))?;
if let Err(e) = execute_command_in_worktree(worktree_path, &prepared.expanded) {
@@ -488,7 +489,8 @@ fn spawn_post_start_commands(
// Spawn each command as a detached background process
for prepared in commands {
- crate::output::progress(format!("πŸ”„ {CYAN}Starting (background):{CYAN:#}"))?;
+ let label = crate::commands::format_command_label("post-start", prepared.name.as_deref());
+ crate::output::progress(format!("πŸ”„ {CYAN}{label}{CYAN:#}"))?;
crate::output::progress(format_bash_with_gutter(&prepared.expanded, ""))?;
let name = prepared.name.as_deref().unwrap_or("cmd");
@@ -553,7 +555,8 @@ pub fn execute_post_start_commands_sequential(
// Execute sequentially for testing
for prepared in commands {
- crate::output::progress(format!("πŸ”„ {CYAN}Executing (post-start):{CYAN:#}"))?;
+ let label = crate::commands::format_command_label("post-start", prepared.name.as_deref());
+ crate::output::progress(format!("πŸ”„ {CYAN}{label}{CYAN:#}"))?;
crate::output::progress(format_bash_with_gutter(&prepared.expanded, ""))?;
if let Err(e) = execute_command_in_worktree(worktree_path, &prepared.expanded) {
diff --git a/tests/integration_tests/shell_wrapper.rs b/tests/integration_tests/shell_wrapper.rs
index 86889083a..c4f30d510 100644
--- a/tests/integration_tests/shell_wrapper.rs
+++ b/tests/integration_tests/shell_wrapper.rs
@@ -848,8 +848,8 @@ command = "echo 'background task'"
// Critical assertion: progress messages should appear to users
// This is the test that catches the bug where progress() is suppressed in directive mode
assert!(
- output.combined.contains("Starting (background)"),
- "Progress message 'Starting (background)' missing from output. \
+ output.combined.contains("Running post-start"),
+ "Progress message 'Running post-start' missing from output. \
Output:\n{}",
output.combined
);
@@ -916,8 +916,8 @@ command = "echo 'fish background task'"
// Critical: progress messages should appear to users through Fish wrapper
assert!(
- output.combined.contains("Starting (background)"),
- "Progress message 'Starting (background)' missing from Fish wrapper output. \
+ output.combined.contains("Running post-start"),
+ "Progress message 'Running post-start' missing from Fish wrapper output. \
Output:\n{}",
output.combined
);
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__fish_wrapper_preserves_progress_messages.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__fish_wrapper_preserves_progress_messages.snap
index 78f9e7843..18d00fc13 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__fish_wrapper_preserves_progress_messages.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__fish_wrapper_preserves_progress_messages.snap
@@ -2,7 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'fish background task'
βœ… Created new worktree for fish-bg at [TMPDIR]/test-repo.fish-bg
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 4c6e97b15..793f6eba1 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
@@ -2,12 +2,12 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Running pre-merge command format:
+πŸ”„ Running pre-merge: format
  echo 'βœ“ Code formatting check passed'
βœ“ Code formatting check passed
-πŸ”„ Running pre-merge command test:
+πŸ”„ Running pre-merge: test
  echo 'βœ— Test suite failed: 3 tests failing' && exit 1
βœ— Test suite failed: 3 tests failing
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_fish.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_fish.snap
index a67b78882..c40d1fdba 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_fish.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_failure_fish.snap
@@ -2,11 +2,11 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Running pre-merge command format:
+πŸ”„ Running pre-merge: format
  echo 'βœ“ Code formatting check passed'
βœ“ Code formatting check passed
-πŸ”„ Running pre-merge command test:
+πŸ”„ Running pre-merge: test
  echo 'βœ— Test suite failed: 3 tests failing' && exit 1
βœ— Test suite failed: 3 tests failing
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 6bf37829c..f0e6bd678 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,9 +9,9 @@ expression: output.normalized().as_ref()
Command failed with exit code: exit status: 1
πŸ’‘ Use --no-hooks to skip pre-merge commands
-πŸ”„ Running pre-merge command format:
+πŸ”„ Running pre-merge: format
  echo 'βœ“ Code formatting check passed'
-πŸ”„ Running pre-merge command test:
+πŸ”„ Running pre-merge: test
  echo 'βœ— Test suite failed: 3 tests failing' && exit 1
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_bash.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_bash.snap
index 967e136cb..929558450 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_bash.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_bash.snap
@@ -2,17 +2,17 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Running pre-merge command format:
+πŸ”„ Running pre-merge: format
  echo 'βœ“ Code formatting check passed'
βœ“ Code formatting check passed
-πŸ”„ Running pre-merge command lint:
+πŸ”„ Running pre-merge: lint
  echo 'βœ“ Linting passed - no warnings'
βœ“ Linting passed - no warnings
-πŸ”„ Running pre-merge command test:
+πŸ”„ Running pre-merge: test
  echo 'βœ“ All 47 tests passed in 2.3s'
βœ“ All 47 tests passed in 2.3s
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_fish.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_fish.snap
index 2a7a3c974..b22da6638 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_fish.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_fish.snap
@@ -2,15 +2,15 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Running pre-merge command format:
+πŸ”„ Running pre-merge: format
  echo 'βœ“ Code formatting check passed'
βœ“ Code formatting check passed
-πŸ”„ Running pre-merge command lint:
+πŸ”„ Running pre-merge: lint
  echo 'βœ“ Linting passed - no warnings'
βœ“ Linting passed - no warnings
-πŸ”„ Running pre-merge command test:
+πŸ”„ Running pre-merge: test
  echo 'βœ“ All 47 tests passed in 2.3s'
βœ“ All 47 tests passed in 2.3s
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_zsh.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_zsh.snap
index 932a76fd4..0e9f1c799 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_zsh.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__merge_with_pre_merge_success_zsh.snap
@@ -5,15 +5,15 @@ expression: output.normalized().as_ref()
βœ“ Code formatting check passed
βœ“ Linting passed - no warnings
βœ“ All 47 tests passed in 2.3s
-πŸ”„ Running pre-merge command format:
+πŸ”„ Running pre-merge: format
  echo 'βœ“ Code formatting check passed'
-πŸ”„ Running pre-merge command lint:
+πŸ”„ Running pre-merge: lint
  echo 'βœ“ Linting passed - no warnings'
-πŸ”„ Running pre-merge command test:
+πŸ”„ Running pre-merge: test
  echo 'βœ“ All 47 tests passed in 2.3s'
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_bash.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_bash.snap
index 97bc371bc..56a23898e 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_bash.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_bash.snap
@@ -2,20 +2,20 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 1
  echo 'Installing dependencies...'
Installing dependencies...
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 2
  echo 'Building project...'
Building project...
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: server
  echo 'Starting dev server on port 3000'
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: watch
  echo 'Watching for file changes'
βœ… Created new worktree for feature-hooks at [TMPDIR]/test-repo.feature-hooks
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_fish.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_fish.snap
index 21b64d4f2..d255cee13 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_fish.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_fish.snap
@@ -2,18 +2,18 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 1
  echo 'Installing dependencies...'
Installing dependencies...
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 2
  echo 'Building project...'
Building project...
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: server
  echo 'Starting dev server on port 3000'
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: watch
  echo 'Watching for file changes'
βœ… Created new worktree for feature-hooks at [TMPDIR]/test-repo.feature-hooks
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_zsh.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_zsh.snap
index bf700149e..6897c6608 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_zsh.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_hooks_zsh.snap
@@ -4,18 +4,18 @@ expression: output.normalized().as_ref()
---
Installing dependencies...
Building project...
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 1
  echo 'Installing dependencies...'
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 2
  echo 'Building project...'
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: server
  echo 'Starting dev server on port 3000'
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: watch
  echo 'Watching for file changes'
βœ… Created new worktree for feature-hooks at [TMPDIR]/test-repo.feature-hooks
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_post_start_command_no_directive_leak.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_post_start_command_no_directive_leak.snap
index ba5a5f504..96c2885ac 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_post_start_command_no_directive_leak.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__switch_with_post_start_command_no_directive_leak.snap
@@ -2,7 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'test command executed'
βœ… Created new worktree for feature-with-hooks at [TMPDIR]/test-repo.feature-with-hooks
diff --git a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__wrapper_preserves_progress_messages.snap b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__wrapper_preserves_progress_messages.snap
index 3eddcc618..885740a54 100644
--- a/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__wrapper_preserves_progress_messages.snap
+++ b/tests/integration_tests/snapshots/integration__integration_tests__shell_wrapper__tests__wrapper_preserves_progress_messages.snap
@@ -2,7 +2,7 @@
source: tests/integration_tests/shell_wrapper.rs
expression: output.normalized().as_ref()
---
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'background task'
βœ… Created new worktree for feature-bg at [TMPDIR]/test-repo.feature-bg
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 5f185dc79..39d1e8287 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
@@ -17,7 +17,7 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpoVUaLF/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp44Y4sI/test-config.toml
---
success: true
exit_code: 0
@@ -34,7 +34,7 @@ exit_code: 0
πŸ”„ Cleaning up worktree...
βœ… Returned to primary at [REPO]
-πŸ”„ Running post-merge command:
+πŸ”„ Running post-merge:
  exit 1
🟑 Command failed: Command failed with exit code: exit status: 1
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_named.snap b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_named.snap
index e60650da4..3de31f1a7 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_named.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_named.snap
@@ -17,7 +17,7 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp91cVDV/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpEGCnAp/test-config.toml
---
success: true
exit_code: 0
@@ -34,10 +34,10 @@ exit_code: 0
πŸ”„ Cleaning up worktree...
βœ… Returned to primary at [REPO]
-πŸ”„ Running post-merge command deploy:
+πŸ”„ Running post-merge: deploy
  echo 'Deploying branch feature' > deploy.txt
-πŸ”„ Running post-merge command notify:
+πŸ”„ Running post-merge: notify
  echo 'Merge to main complete' > notify.txt
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_success.snap b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_success.snap
index 151dc606c..c3b57d39d 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_success.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_success.snap
@@ -17,7 +17,7 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp7Rysra/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp3cHHCs/test-config.toml
---
success: true
exit_code: 0
@@ -34,7 +34,7 @@ exit_code: 0
πŸ”„ Cleaning up worktree...
βœ… Returned to primary at [REPO]
-πŸ”„ Running post-merge command:
+πŸ”„ Running post-merge:
  echo 'merged feature to main' > post-merge-ran.txt
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_combined_output.snap b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_combined_output.snap
index 3f6fb1165..a74a91ea5 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_combined_output.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_combined_output.snap
@@ -3,12 +3,12 @@ source: tests/integration_tests/merge.rs
expression: output
---
Exit code: 0
-πŸ”„ Running pre-merge command first:
+πŸ”„ Running pre-merge: first
  echo 'STDOUT-FROM-FIRST' && echo 'STDERR-FROM-FIRST' >&2
STDOUT-FROM-FIRST
STDERR-FROM-FIRST
-πŸ”„ Running pre-merge command second:
+πŸ”„ Running pre-merge: second
  echo 'STDOUT-FROM-SECOND' && echo 'STDERR-FROM-SECOND' >&2
STDOUT-FROM-SECOND
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 bea8104e4..854bcca8b 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpUQwx9m/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp94U8xj/test-config.toml
---
success: false
exit_code: 1
----- stdout -----
-πŸ”„ Running pre-merge command:
+πŸ”„ Running pre-merge:
  exit 1
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_named.snap b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_named.snap
index 3ce1d7590..74ce28029 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_named.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_named.snap
@@ -17,18 +17,18 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp2PnhTr/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpySXfo5/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Running pre-merge command format:
+πŸ”„ Running pre-merge: format
  exit 0
-πŸ”„ Running pre-merge command lint:
+πŸ”„ Running pre-merge: lint
  exit 0
-πŸ”„ Running pre-merge command test:
+πŸ”„ Running pre-merge: test
  exit 0
πŸ”„ Rebasing onto main...
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_stdout_stderr_ordering.snap b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_stdout_stderr_ordering.snap
index b3f02d834..f11e0548f 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_stdout_stderr_ordering.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_stdout_stderr_ordering.snap
@@ -17,15 +17,15 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpW2WaUb/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpQtLd9m/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Running pre-merge command check1:
+πŸ”„ Running pre-merge: check1
  [PROJECT_ROOT]/tests/fixtures/mixed-output.sh check1 3
-πŸ”„ Running pre-merge command check2:
+πŸ”„ Running pre-merge: check2
  [PROJECT_ROOT]/tests/fixtures/mixed-output.sh check2 3
πŸ”„ Rebasing onto main...
diff --git a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_success.snap b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_success.snap
index 41ef68142..cf3b29f2f 100644
--- a/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_success.snap
+++ b/tests/snapshots/integration__integration_tests__merge__merge_pre_merge_command_success.snap
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpVkQo4K/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpOMFxAN/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Running pre-merge command:
+πŸ”„ Running pre-merge:
  exit 0
πŸ”„ Rebasing onto main...
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 6e937c1b6..00151cf82 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
@@ -17,15 +17,15 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpq2cN92/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpo60Axs/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create:
  echo 'Setup done' > setup.txt
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: server
  sleep 0.5 && echo 'Server running' > server.txt
βœ… Created new worktree for feature at [REPO].feature
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snap b/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snap
index 8ff908a4e..6482b5610 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__execute_with_post_start.snap
@@ -19,12 +19,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpA4nIH0/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpiln4ET/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'Background task' > background.txt
βœ… Created new worktree for feature at [REPO].feature
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 80ca84625..8da60cff9 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp9ZhOmu/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpeIQPNl/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create:
  exit 1
🟑 Command failed: Command failed with exit code: exit status: 1
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 6f8c5d8c9..6ab21ae95 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpCIVxhL/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpJzbw9X/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create:
  if [ ! -f test.txt ]; then
  echo 'File does not exist' > result.txt
  else
diff --git a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiple_commands_array.snap b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiple_commands_array.snap
index 5b70ed11d..bd2f8f189 100644
--- a/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiple_commands_array.snap
+++ b/tests/snapshots/integration__integration_tests__post_start_commands__post_create_multiple_commands_array.snap
@@ -17,15 +17,15 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp9bj8m8/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpdPKQvs/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 1
  echo 'First'
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 2
  echo 'Second'
βœ… Created new worktree for feature at [REPO].feature
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 ca126069f..71683437b 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
@@ -17,15 +17,15 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpUoNDWb/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpfqP0vf/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: install
  echo 'Installing deps'
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: setup
  echo 'Running setup'
βœ… Created new worktree for feature at [REPO].feature
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 8e60b3bcd..9e0b6bfa0 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpnKKTEx/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp2xdqGN/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create:
  echo 'Setup complete'
βœ… Created new worktree for feature at [REPO].feature
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 b2d2f3652..2eb0f3c27 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
@@ -17,21 +17,21 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpsA9gbG/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpDTK7pT/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 1
  echo 'Repo: test-repo' > info.txt
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 2
  echo 'Branch: feature-test' >> info.txt
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 3
  echo 'Worktree: [REPO].feature-test' >> info.txt
-πŸ”„ Executing (post-create):
+πŸ”„ Running post-create: 4
  echo 'Root: [REPO]' >> info.txt
βœ… Created new worktree for feature/test at [REPO].feature-test
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 311477dc4..e02a1ef1a 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp5zSzoe/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpx7u9uZ/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'line1
  line2
  line3' | grep line2 > filtered.txt
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 ff959bd13..e02f28fef 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmplr7P8Y/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpulSoY3/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'unclosed quote
βœ… Created new worktree for feature at [REPO].feature
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 9c2fa0432..bbee89fdc 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpyugcH2/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpo2wwac/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'stdout output' && echo 'stderr output' >&2
βœ… Created new worktree for feature at [REPO].feature
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 34c2096b2..7e3656dac 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpNYMKbD/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpfQS2u4/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  echo 'first line' > multiline.txt
  echo 'second line' >> multiline.txt
  echo 'third line' >> multiline.txt
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 45259dda4..f86e91219 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
@@ -17,15 +17,15 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpYeW6bk/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpSA3UaZ/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: task1
  echo 'Task 1 running' > task1.txt
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: task2
  echo 'Task 2 running' > task2.txt
βœ… Created new worktree for feature at [REPO].feature
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 7e922d902..7eb657707 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
@@ -17,18 +17,18 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmptz6odB/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpBD9Ve9/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: task1
  echo 'TASK1_OUTPUT'
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: task2
  echo 'TASK2_OUTPUT'
-πŸ”„ Starting (background):
+πŸ”„ Running post-start: task3
  echo 'TASK3_OUTPUT'
βœ… Created new worktree for feature at [REPO].feature
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 ff95afc62..3ff1edcd8 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
@@ -17,12 +17,12 @@ info:
LANG: C
LC_ALL: C
SOURCE_DATE_EPOCH: "1761609600"
- WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpLJlECk/test-config.toml
+ WORKTRUNK_CONFIG_PATH: /var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp6WjLOS/test-config.toml
---
success: true
exit_code: 0
----- stdout -----
-πŸ”„ Starting (background):
+πŸ”„ Running post-start:
  sleep 1 && echo 'Background task done' > background.txt
βœ… Created new worktree for feature at [REPO].feature