1717 ref : ${{ github.event.release.tag_name }}
1818 fetch-depth : 0
1919
20+ - name : Resolve release commit SHA
21+ id : release_sha
22+ working-directory : source
23+ run : echo "sha=$(git rev-parse HEAD)" >> "$GITHUB_OUTPUT"
24+
2025 - name : Checkout Flathub manifest repo
2126 uses : actions/checkout@v4
2227 with :
@@ -37,22 +42,18 @@ jobs:
3742 - name : Copy cargo-sources.json into Flathub repo
3843 run : cp source/cargo-sources.json flathub/cargo-sources.json
3944
40- - name : Pin manifest to release tag/ commit
45+ - name : Pin manifest to release commit
4146 working-directory : flathub
4247 env :
43- RELEASE_TAG : ${{ github.event.release.tag_name }}
44- RELEASE_COMMIT : ${{ github.sha }}
45- REPO_URL : https://github.com/${{ github.repository }}.git
48+ RELEASE_COMMIT : ${{ steps.release_sha.outputs.sha }}
4649 run : |
4750 MANIFEST="dev.edfloreshz.CosmicTweaks.json"
4851
49- jq --arg url "$REPO_URL" \
50- --arg tag "$RELEASE_TAG" \
51- --arg commit "$RELEASE_COMMIT" \
52+ jq --arg commit "$RELEASE_COMMIT" \
5253 '(.modules[] | select(.name == "tweaks") | .sources) |=
5354 map(
54- if type == "object" and .type == "dir " then
55- {"type": "git", "url": $url, "tag": $tag, " commit": $commit}
55+ if type == "object" and .type == "git " then
56+ .commit = $ commit
5657 else . end
5758 )
5859 ' "$MANIFEST" > "$MANIFEST.tmp"
0 commit comments