diff --git a/.github/workflows/sync-upstream.yml b/.github/workflows/sync-upstream.yml index bd60234..56a9b94 100644 --- a/.github/workflows/sync-upstream.yml +++ b/.github/workflows/sync-upstream.yml @@ -68,6 +68,12 @@ jobs: ./$project/metadata.json | tee ./$project/metadata.json.tmp # Replace the original file mv ./$project/{metadata.json.tmp,metadata.json} + # Update vendorHash + vendor=$(nix --log-format raw build .#$project 2>&1 | grep "got: " | awk '/got: / {print $NF}' || echo "") + jq --arg vendor "$vendor" \ + '.vendorHash = $vendor' \ + ./$project/metadata.json | tee ./$project/metadata.json.tmp + mv ./$project/{metadata.json.tmp,metadata.json} - name: Commit changes and push uses: EndBug/add-and-commit@main