Whether git shadow sync is established for this repo (the `.git/info/exclude` carries Atomic's shadow patterns, written by import/push). Used to gate the view-switch git-follow so we never touch HEAD in a plain (non-shadow) repo. NOTE: this marker is *retained* by `git shim disable` and by plain `atomic init` inside an existing Git checkout — it is not enrollment. Use [`shim_workspace_enrolled`] w
(git_repo: &GitRepository)
| 1900 | /// `atomic init` inside an existing Git checkout — it is not enrollment. Use |
| 1901 | /// [`shim_workspace_enrolled`] wherever the question is shim participation. |
| 1902 | fn shadow_sync_active(git_repo: &GitRepository) -> bool { |
| 1903 | let exclude = git_repo.path().join("info").join("exclude"); |
| 1904 | std::fs::read_to_string(exclude) |
| 1905 | .map(|c| c.lines().any(|l| l.trim() == "/.atomic/")) |
| 1906 | .unwrap_or(false) |
| 1907 | } |
| 1908 | |
| 1909 | /// Whether the working copy at `root` participates in the colocated Git |
| 1910 | /// shim: a verified checkpoint (written by an explicit shim command) or |
no test coverage detected