Skip to content

Commit

Permalink
fix bug in instantiate
Browse files Browse the repository at this point in the history
  • Loading branch information
KristofferC committed May 23, 2018
1 parent 652fd30 commit b017863
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion stdlib/Pkg/src/API.jl
Original file line number Diff line number Diff line change
Expand Up @@ -508,14 +508,21 @@ function instantiate(ctx::Context; manifest::Union{Bool, Nothing}=nothing, kwarg
pkg.path !== nothing && continue
urls[pkg.uuid] = String[]
hashes[pkg.uuid] = SHA1(info["git-tree-sha1"])

if haskey(info, "repo-url")
pkg.repo = Types.GitRepo(
info["repo-url"],
info["repo-rev"],
SHA1(info["git-tree-sha1"]))
end
end
end
_, urls_ref = Operations.version_data!(ctx, pkgs)
for (uuid, url) in urls_ref
append!(urls[uuid], url)
urls[uuid] = unique(urls[uuid])
end
new_git = handle_repos_add!(ctx, pkgs; upgrade_or_add=true)
new_git = handle_repos_add!(ctx, pkgs; upgrade_or_add=false)
new_apply = Operations.apply_versions(ctx, pkgs, hashes, urls)
Operations.build_versions(ctx, union(new_apply, new_git))
end
Expand Down

0 comments on commit b017863

Please sign in to comment.