Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move Artifacts and BinaryPlatforms out of Pkg #2001

Merged
merged 1 commit into from
Sep 15, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ desc = "The next-generation Julia package manager."
version = "1.5.0"

[deps]
Artifacts = "56f22d72-fd6d-98f1-02f0-08ddc0907c33"
Dates = "ade2ca70-3891-5945-98fb-dc099432e06a"
LibGit2 = "76f85450-5226-5b5a-8eaa-529ad045b433"
Libdl = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
Expand Down
2 changes: 1 addition & 1 deletion docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ if "pdf" in ARGS
end

# setup for doctesting
DocMeta.setdocmeta!(Pkg.BinaryPlatforms, :DocTestSetup, :(using Pkg.BinaryPlatforms); recursive=true)
DocMeta.setdocmeta!(Pkg.BinaryPlatforms, :DocTestSetup, :(using Base.BinaryPlatforms); recursive=true)

# Run doctests first and disable them in makedocs
Documenter.doctest(joinpath(@__DIR__, "src"), [Pkg])
Expand Down
8 changes: 4 additions & 4 deletions src/API.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import ..depots, ..depots1, ..logdir, ..devdir
import ..Operations, ..GitTools, ..Pkg, ..UPDATED_REGISTRY_THIS_SESSION
using ..Types, ..TOML
using ..Types: VersionTypes
using ..BinaryPlatforms
using Base.BinaryPlatforms
using ..Artifacts: artifact_paths

include("generate.jl")
Expand Down Expand Up @@ -89,7 +89,7 @@ for f in (:develop, :add, :rm, :up, :pin, :free, :test, :build, :status)
end

function develop(ctx::Context, pkgs::Vector{PackageSpec}; shared::Bool=true,
preserve::PreserveLevel=PRESERVE_TIERED, platform::Platform=platform_key_abi(), kwargs...)
preserve::PreserveLevel=PRESERVE_TIERED, platform::AbstractPlatform=HostPlatform(), kwargs...)
require_not_empty(pkgs, :develop)
foreach(pkg -> check_package_name(pkg.name, :develop), pkgs)
pkgs = deepcopy(pkgs) # deepcopy for avoid mutating PackageSpec members
Expand Down Expand Up @@ -135,7 +135,7 @@ function develop(ctx::Context, pkgs::Vector{PackageSpec}; shared::Bool=true,
end

function add(ctx::Context, pkgs::Vector{PackageSpec}; preserve::PreserveLevel=PRESERVE_TIERED,
platform::Platform=platform_key_abi(), kwargs...)
platform::AbstractPlatform=HostPlatform(), kwargs...)
require_not_empty(pkgs, :add)
foreach(pkg -> check_package_name(pkg.name, :add), pkgs)
pkgs = deepcopy(pkgs) # deepcopy for avoid mutating PackageSpec members
Expand Down Expand Up @@ -935,7 +935,7 @@ end
instantiate(; kwargs...) = instantiate(Context(); kwargs...)
function instantiate(ctx::Context; manifest::Union{Bool, Nothing}=nothing,
update_registry::Bool=true, verbose::Bool=false,
platform::Platform=platform_key_abi(), kwargs...)
platform::AbstractPlatform=HostPlatform(), kwargs...)
Context!(ctx; kwargs...)
if !isfile(ctx.env.project_file) && isfile(ctx.env.manifest_file)
_manifest = Pkg.Types.read_manifest(ctx.env.manifest_file)
Expand Down