Skip to content

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

Refactor: Use `main_worktree_root` for project config

Maximilian Roosf267c8ae687c
diff --git a/src/commands/config.rs b/src/commands/config.rs
index f8bfb5a88..c004aed5e 100644
--- a/src/commands/config.rs
+++ b/src/commands/config.rs
@@ -62,7 +62,7 @@ fn display_project_config() -> Result<(), GitError> {
// Try to get current repository root
let repo = Repository::current();
- let repo_root = match repo.repo_root() {
+ let repo_root = match repo.main_worktree_root() {
Ok(root) => root,
Err(_) => {
println!("Project Config: {dim}Not in a git repository{dim:#}");
diff --git a/src/commands/worktree.rs b/src/commands/worktree.rs
index 7ef660e23..cd75857f1 100644
--- a/src/commands/worktree.rs
+++ b/src/commands/worktree.rs
@@ -101,7 +101,7 @@
//! See also: DEMO.md for detailed architecture explanation.
use std::collections::HashMap;
-use std::io::{self, Write};
+use std::io;
use std::path::PathBuf;
use worktrunk::config::{ProjectConfig, WorktrunkConfig, expand_template};
use worktrunk::git::{GitError, Repository};