MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / shim_workspace_enrolled

Function shim_workspace_enrolled

atomic-cli/src/commands/git/shadow.rs:2102–2105  ·  view source on GitHub ↗

Whether the working copy at `root` participates in the colocated Git shim: a verified checkpoint (written by an explicit shim command) or the explicit `[git.shim] enabled` opt-in (RFC §2 / CB-13C). A `.git` directory next to `.atomic` — with or without a retained shadow exclude line — is not consent.

(root: &Path)

Source from the content-addressed store, hash-verified

2100/// directory next to `.atomic` — with or without a retained shadow exclude
2101/// line — is not consent.
2102pub(crate) fn shim_workspace_enrolled(root: &Path) -> CliResult<bool> {
2103 let repo = Repository::open_readonly(root).map_err(CliError::Repository)?;
2104 repo.shim_workspace_active().map_err(CliError::Repository)
2105}
2106
2107/// Acquire the repo-scoped shadow-commit lock, or return `None` (a no-op skip)
2108/// if a shadow materialize/commit is already in flight (SPEC §4.3 / Principle 5).

Callers 1

checkpoint_shadow_switchFunction · 0.85

Calls 1

shim_workspace_activeMethod · 0.80

Tested by

no test coverage detected