Skip to main content

resolve

Function resolve 

Source
pub fn resolve(
    home: &Path,
    name: &str,
    url: &str,
    reference: &GitReference,
    locked_commit: Option<&str>,
    offline: bool,
) -> Result<(PathBuf, String)>
Expand description

Resolve a git dependency to a (checkout_directory, commit_hash).

A locked_commit from leo.lock is reused when its checkout exists and the reference is immutable (tag/rev) or offline; a mutable reference re-resolves against the remote when online. offline forbids network access, so it then succeeds only from an existing checkout.