tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
0
fork
atom
lol
0
fork
atom
overview
issues
pulls
pipelines
swiftpm2nix: fix hash mismatch when git submodules exist
Emily Trau
2 years ago
b732363e
9aafa9b2
+2
-1
2 changed files
expand all
collapse all
unified
split
pkgs
development
tools
swiftpm2nix
support.nix
swiftpm2nix.sh
+1
pkgs/development/tools/swiftpm2nix/support.nix
···
29
29
url = dep.packageRef.location;
30
30
rev = dep.state.checkoutState.revision;
31
31
sha256 = hashes.${dep.subpath};
32
32
+
fetchSubmodules = true;
32
33
})) workspaceState.object.dependencies
33
34
);
34
35
+1
-1
pkgs/development/tools/swiftpm2nix/swiftpm2nix.sh
···
23
23
jq -r '.object.dependencies[] | "\(.subpath) \(.packageRef.location) \(.state.checkoutState.revision)"' $stateFile \
24
24
| while read -r name url rev; do
25
25
echo >&2 "-- Fetching $name"
26
26
-
sha256="$(nix-prefetch-git $url $rev | jq -r .sha256)"
26
26
+
sha256="$(nix-prefetch-git --fetch-submodules $url $rev | jq -r .sha256)"
27
27
hashes+="
28
28
\"$name\" = \"$sha256\";"
29
29
echo >&2