pub struct Compose {
pub root: PathBuf,
pub global: Global,
pub projects: Vec<Project>,
}Expand description
Fully loaded compose tree: global + resolved projects.
Fields§
§root: PathBuf§global: Global§projects: Vec<Project>Implementations§
Source§impl Compose
impl Compose
Sourcepub fn discover(start: &Path) -> Result<PathBuf>
pub fn discover(start: &Path) -> Result<PathBuf>
Walk up from start looking for the first .team/team-compose.yaml
and return the directory containing the compose file (the “root”),
suitable for passing to Compose::load. The first hit wins; we do
not keep walking past it to look for a parent .team/.
This is the equivalent of git’s .git/ discovery — once a repo carries
a .team/ folder, every teamctl subcommand finds it from anywhere
inside the tree. T-008 retired the legacy flat-layout fallback and
the second-hit / parent-.team/ walk: the convention is .team/ and
the nearest one wins, no exceptions.
Sourcepub fn load(root: impl AsRef<Path>) -> Result<Self>
pub fn load(root: impl AsRef<Path>) -> Result<Self>
Parse team-compose.yaml at root and every referenced project file.
Sourcepub fn agents(&self) -> impl Iterator<Item = AgentHandle<'_>>
pub fn agents(&self) -> impl Iterator<Item = AgentHandle<'_>>
Return every agent in the compose tree tagged with manager/worker.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Compose
impl RefUnwindSafe for Compose
impl Send for Compose
impl Sync for Compose
impl Unpin for Compose
impl UnsafeUnpin for Compose
impl UnwindSafe for Compose
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more