cargo::sources::git::source

Function ident_shallow

Source
fn ident_shallow(id: &SourceId, is_shallow: bool) -> String
Expand description

Like ident(), but appends -shallow to it, turning proto://host/path/repo into repo-<hash-of-url>-shallow.

It’s important to separate shallow from non-shallow clones for reasons of backwards compatibility — older cargo’s aren’t necessarily handling shallow clones correctly.