The conversion policy content key for one capture boundary.
(root: &std::path::Path)
| 324 | |
| 325 | /// The conversion policy content key for one capture boundary. |
| 326 | fn policy_root_for_capture(root: &std::path::Path) -> Result<String, RepositoryError> { |
| 327 | let policy = |
| 328 | super::conversion_policy_for_git(&git2::Repository::discover(root).map_err(|error| { |
| 329 | RepositoryError::InvalidRepository { |
| 330 | reason: format!("cannot open the Git repository for capture: {error}"), |
| 331 | } |
| 332 | })?) |
| 333 | .map_err(|error| RepositoryError::InvalidOperation { |
| 334 | message: format!("cannot compute conversion policy for capture: {error}"), |
| 335 | })?; |
| 336 | Ok(policy.root().content_key) |
| 337 | } |
| 338 | |
| 339 | impl Repository { |
| 340 | /// Whether the working copy's private snapshot view holds an active |
no test coverage detected