Skip to main content

ralph/git/workspace/
mod.rs

1//! Git workspace helpers for parallel task isolation.
2//!
3//! Responsibilities:
4//! - Re-export workspace path, lifecycle, and remote helpers behind a thin facade.
5//! - Keep crate-facing git workspace APIs stable while delegating focused concerns.
6//! - Centralize module-level invariants for workspace management.
7//!
8//! Not handled here:
9//! - Task orchestration, PR workflows, or integration conflict policy.
10//! - Generic filesystem helpers outside workspace lifecycle concerns.
11//!
12//! Invariants/assumptions:
13//! - Workspace paths are unique per task ID.
14//! - Clones must be retargeted to a pushable `origin` remote before use.
15
16mod git_ops;
17mod lifecycle;
18mod paths;
19
20pub(crate) use git_ops::origin_urls;
21pub(crate) use lifecycle::{WorkspaceSpec, create_workspace_at, remove_workspace};
22pub(crate) use paths::workspace_root;
23
24#[cfg(test)]
25pub(crate) use lifecycle::ensure_workspace_exists;
26
27#[cfg(test)]
28mod tests;