Skip to content

Commit

Permalink
fix precompiling packages specifically (#4014)
Browse files Browse the repository at this point in the history
  • Loading branch information
IanButterworth committed Sep 4, 2024
1 parent 299a356 commit 8597c4e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
1 change: 1 addition & 0 deletions src/REPLMode/command_declarations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,7 @@ Create a minimal project called `pkgname` in the current folder. For more featur
],
PSA[:name => "precompile",
:api => API.precompile,
:should_splat => false,
:arg_count => 0 => Inf,
:completions => :complete_installed_packages,
:description => "precompile all the project dependencies",
Expand Down
12 changes: 5 additions & 7 deletions test/new.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2229,19 +2229,17 @@ end

api, arg, opts = first(Pkg.pkg"precompile Foo")
@test api == Pkg.precompile
@test arg == "Foo"
@test arg == ["Foo"]
@test isempty(opts)

api, arg1, arg2, opts = first(Pkg.pkg"precompile Foo Bar")
api, arg, opts = first(Pkg.pkg"precompile Foo Bar")
@test api == Pkg.precompile
@test arg1 == "Foo"
@test arg2 == "Bar"
@test arg == ["Foo", "Bar"]
@test isempty(opts)

api, arg1, arg2, opts = first(Pkg.pkg"precompile Foo, Bar")
api, arg, opts = first(Pkg.pkg"precompile Foo, Bar")
@test api == Pkg.precompile
@test arg1 == "Foo"
@test arg2 == "Bar"
@test arg == ["Foo", "Bar"]
@test isempty(opts)
end
end
Expand Down

0 comments on commit 8597c4e

Please sign in to comment.