Skip to content

Commit bd72690

Browse files
authored
Merge pull request #14069 from infosiftr/diff-pr-external-pins
Update external-pins diffing to match normal diffing
2 parents a6ff0f4 + 77fbe15 commit bd72690

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

diff-pr.sh

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,17 @@ _metadata-files() {
295295
mkdir -p "$dir"
296296
bashbrew remote arches --json "$pin@$digest" | jq -S . > "$dir/bashbrew.json"
297297
local manifests manifest
298-
manifests="$(jq -r '[ .arches[][].digest | @sh ] | join(" ")' "$dir/bashbrew.json")"
298+
manifests="$(jq -r '
299+
[ (
300+
.arches
301+
| if has(env.BASHBREW_ARCH) then
302+
.[env.BASHBREW_ARCH]
303+
else
304+
.[keys_unsorted | first]
305+
end
306+
)[].digest | @sh ]
307+
| join(" ")
308+
' "$dir/bashbrew.json")"
299309
eval "manifests=( $manifests )"
300310
for manifest in "${manifests[@]}"; do
301311
crane manifest "$pin@$manifest" | jq -S . > "$dir/manifest-${manifest//:/_}.json"

0 commit comments

Comments
 (0)