Merge pull request #137 from nix-community/nixpkgs-upstream

no longer delete existing assets
This commit is contained in:
Jörg Thalheim 2023-11-02 12:44:58 +01:00 committed by GitHub
commit 25f4c4dddd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -45,13 +45,6 @@ main() {
gh release create --title "$tag (build $(date +"%Y-%m-%d"))" "$tag"
fi
gh release upload --clobber "$tag" "${assets[@]}"
gh release view --json assets | jq -r ".assets | map(.name) | .[] | select(test(\"$arch\"))" >"$TMP/existing-assets"
for asset in "${assets[@]}"; do
basename "$asset" >>"$TMP/uploaded-assets"
done
sort "$TMP/uploaded-assets" "$TMP/existing-assets" | uniq -u | xargs --no-run-if-empty -I{} gh release delete-asset --yes "$tag" {}
}
main "$@"