Bump git2.

This commit is contained in:
Eric Huss 2020-04-23 09:31:33 -07:00
parent 3a5af295d8
commit 25715e4f2a
2 changed files with 4 additions and 8 deletions

View file

@ -32,7 +32,7 @@ pretty_env_logger = { version = "0.4", optional = true }
anyhow = "1.0"
filetime = "0.2.9"
flate2 = { version = "1.0.3", default-features = false, features = ["zlib"] }
git2 = "0.13.1"
git2 = "0.13.5"
git2-curl = "0.14.0"
glob = "0.3.0"
hex = "0.4"
@ -44,7 +44,7 @@ jobserver = "0.1.21"
lazycell = "1.2.0"
libc = "0.2"
log = "0.4.6"
libgit2-sys = "0.12.1"
libgit2-sys = "0.12.5"
memchr = "2.1.3"
num_cpus = "1.0"
opener = "0.4"

View file

@ -204,12 +204,8 @@ impl<'cfg> PathSource<'cfg> {
root.display()
)
})?;
// Git requires forward-slashes.
let repo_safe_path = repo_relative_path
.join("Cargo.toml")
.to_string_lossy()
.replace('\\', "/");
if index.get_path(Path::new(&repo_safe_path), 0).is_some() {
let manifest_path = repo_relative_path.join("Cargo.toml");
if index.get_path(&manifest_path, 0).is_some() {
return Ok(Some(self.list_files_git(pkg, &repo, filter)?));
}
// Package Cargo.toml is not in git, don't use git to guide our selection.