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

Method read_current_view

atomic-repository/src/repository/mod.rs:1374–1377  ·  view source on GitHub ↗

Read the legacy compatibility pointer. Persistent working-copy records are authoritative for all ordinary opens; this helper remains for native repair and deferred-TREE compatibility paths.

(dot_dir: &Path)

Source from the content-addressed store, hash-verified

1372 /// are authoritative for all ordinary opens; this helper remains for native
1373 /// repair and deferred-TREE compatibility paths.
1374 fn read_current_view(dot_dir: &Path) -> Result<String, RepositoryError> {
1375 Ok(Self::read_current_view_if_present(dot_dir)?
1376 .unwrap_or_else(|| DEFAULT_STACK.to_string()))
1377 }
1378
1379 fn read_current_view_if_present(dot_dir: &Path) -> Result<Option<String>, RepositoryError> {
1380 for name in ["current_view", "current_stack"] {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected