Skip to content

Commit

Permalink
Copying only .toml files to destination path
Browse files Browse the repository at this point in the history
To avoid copying populated project folders, especially when the
.toml file is referring to a project and not a package dependency
  • Loading branch information
Elvis Aguero committed Jul 24, 2024
1 parent c235cde commit 29d440d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/DepotDelivery.jl
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,11 @@ function build(path::String; platform = Base.BinaryPlatforms.HostPlatform(), ver
# Disabling precompile for non-host platforms
precompiled ? delete!(ENV, "JULIA_PKG_PRECOMPILE_AUTO") : ENV["JULIA_PKG_PRECOMPILE_AUTO"] = "0"

cp(path, joinpath(depot, "dev", name)) # Copy project into dev/
for file in filter(f -> endswith(f, ".toml"), readdir(path))
# Copy .toml files into dev/
cp(joinpath(path, file), joinpath(depot, "dev", name, file), force=true)
end

Pkg.activate(joinpath(depot, "dev", name))
Pkg.instantiate(; platform, verbose)

Expand Down

0 comments on commit 29d440d

Please sign in to comment.