Function cargo::ops::cargo_package::check_repo_state

source ยท
fn check_repo_state(
    p: &Package,
    src_files: &[PathBuf],
    gctx: &GlobalContext
) -> CargoResult<Option<VcsInfo>>
Expand description

Checks if the package source is in a git DVCS repository. If git, and the source is dirty (e.g., has uncommitted changes) then bail! with an informative message. Otherwise return the sha1 hash of the current HEAD commit, or None if no repo is found.