Skip to content

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

feat: Rename `dev` subcommand to `beta`

Maximilian Roos743be8533f7b
diff --git a/src/commands/completion.rs b/src/commands/completion.rs
index 986723471..ed0749512 100644
--- a/src/commands/completion.rs
+++ b/src/commands/completion.rs
@@ -73,10 +73,10 @@ fn parse_completion_context(args: &[String]) -> CompletionContext {
}
}
- // Handle dev subcommand
- if subcommand == "dev" && args.len() >= 3 {
- let dev_subcommand = &args[2];
- if dev_subcommand == "run-hook" {
+ // Handle beta subcommand
+ if subcommand == "beta" && args.len() >= 3 {
+ let beta_subcommand = &args[2];
+ if beta_subcommand == "run-hook" {
// Complete hook types for the positional argument
return CompletionContext::DevRunHook;
}
@@ -270,8 +270,8 @@ mod tests {
#[test]
fn test_parse_completion_context_dev_run_hook() {
- // "wt dev run-hook <cursor>"
- let args = vec!["wt".to_string(), "dev".to_string(), "run-hook".to_string()];
+ // "wt beta run-hook <cursor>"
+ let args = vec!["wt".to_string(), "beta".to_string(), "run-hook".to_string()];
assert_eq!(
parse_completion_context(&args),
CompletionContext::DevRunHook
@@ -280,10 +280,10 @@ mod tests {
#[test]
fn test_parse_completion_context_dev_run_hook_partial() {
- // "wt dev run-hook po<cursor>"
+ // "wt beta run-hook po<cursor>"
let args = vec![
"wt".to_string(),
- "dev".to_string(),
+ "beta".to_string(),
"run-hook".to_string(),
"po".to_string(),
];
@@ -295,8 +295,8 @@ mod tests {
#[test]
fn test_parse_completion_context_dev_only() {
- // "wt dev <cursor>" - should not complete
- let args = vec!["wt".to_string(), "dev".to_string()];
+ // "wt beta <cursor>" - should not complete
+ let args = vec!["wt".to_string(), "beta".to_string()];
assert_eq!(parse_completion_context(&args), CompletionContext::Unknown);
}
}
diff --git a/tests/integration_tests/completion.rs b/tests/integration_tests/completion.rs
index b68dce01c..3854a6c9e 100644
--- a/tests/integration_tests/completion.rs
+++ b/tests/integration_tests/completion.rs
@@ -710,12 +710,12 @@ fn test_complete_dev_run_hook_shows_hook_types() {
let temp = TestRepo::new();
temp.commit("initial");
- // Test completion for dev run-hook
+ // Test completion for beta run-hook
let mut cmd = wt_command();
temp.clean_cli_env(&mut cmd);
let output = cmd
.current_dir(temp.root_path())
- .args(["complete", "wt", "dev", "run-hook", ""])
+ .args(["complete", "wt", "beta", "run-hook", ""])
.output()
.unwrap();
@@ -742,7 +742,7 @@ fn test_complete_dev_run_hook_with_partial_input() {
temp.clean_cli_env(&mut cmd);
let output = cmd
.current_dir(temp.root_path())
- .args(["complete", "wt", "dev", "run-hook", "po"])
+ .args(["complete", "wt", "beta", "run-hook", "po"])
.output()
.unwrap();