Skip to content

Commit

Permalink
Merge package info
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelHatherly committed Jun 18, 2024
1 parent ff54ffa commit b0cf700
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/code_stripping.jl
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ function _generate_stripped_registry(;
stripped_info = get!(Dict, registry_contents, pkg_path)
for (k, v) in info[pkg_path]
k == "Versions.toml" && continue
stripped_info[k] = v
stripped_info[k] = merge(get(Dict, stripped_info, k), v)
end

versions_toml =
Expand All @@ -183,8 +183,6 @@ function _generate_stripped_registry(;

packages[string(package_uuid)] =
Dict("name" => pkg_entry.name, "path" => pkg_path)

break
end
end
end
Expand Down Expand Up @@ -238,7 +236,7 @@ function _write_stripped_registry(stripped_registry, registry_contents)
for (k, v) in data
if endswith(k, ".toml")
open(joinpath(path, k), "w") do io
TOML.print(io, v)
TOML.print(io, v; sorted = true)
end
else
error("Unknown file type: $k")
Expand Down

0 comments on commit b0cf700

Please sign in to comment.