workmux 0.1.164

An opinionated workflow tool that orchestrates git worktrees and tmux
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use crate::git;
use anyhow::{Context, Result};

pub fn run(name: &str) -> Result<()> {
    // Smart resolution: try handle first, then branch name
    let (path, _branch) = git::find_worktree(name).with_context(|| {
        format!(
            "No worktree found with name '{}'. Use 'workmux list' to see available worktrees.",
            name
        )
    })?;
    println!("{}", path.display());
    Ok(())
}