Skip to content

Commit

Permalink
Fix #14205, package installation on a network drive on Windows
Browse files Browse the repository at this point in the history
also see #12166 and git-for-windows/git#554
and https://groups.google.com/forum/#!msg/msysgit/5J3ELvZND0s/2VPm-eUf0YMJ

when doing a clone from a local bare repository, need file:// prefix for it
to work correctly when on a Windows network drive

this is only an issue on release-0.4, libgit2 on master appears to work correctly
  • Loading branch information
tkelman committed Dec 2, 2015
1 parent 084c906 commit 906288e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion base/pkg/write.jl
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ function install(pkg::AbstractString, sha1::AbstractString)
if isdir(".trash/$pkg")
mv(".trash/$pkg", "./$pkg")
else
Git.run(`clone -q $(Cache.path(pkg)) $pkg`)
fileprefix = @windows? "file://" : ""
Git.run(`clone -q $(fileprefix * Cache.path(pkg)) $pkg`)
end
fetch(pkg, sha1)
checkout(pkg, sha1)
Expand Down

2 comments on commit 906288e

@tkelman
Copy link
Contributor Author

@tkelman tkelman commented on 906288e Dec 2, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@StefanKarpinski I'd appreciate if you could sanity check this for me, let me know if you see any possible downsides from this? It's only needed on release-0.4, so will need to test prerelease binaries with this change.

@StefanKarpinski
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks sane to me, although I have no idea about the Windows side.

Please sign in to comment.