forked from git-mirrors/GeyserConnect
Don't use tee to write metadata.json to downloads API
This commit is contained in:
parent
f31601a3a0
commit
1c8c0386da
1 changed files with 4 additions and 2 deletions
6
.github/workflows/build.yml
vendored
6
.github/workflows/build.yml
vendored
|
@ -54,13 +54,15 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
cat metadata.json
|
cat metadata.json
|
||||||
echo
|
echo
|
||||||
|
mv metadata.json metadata.json.tmp
|
||||||
version=$(cat build.gradle | grep -o "version '[0-9\\.]*'" | cut -d" " -f2 | sed "s/'//g")
|
version=$(cat build.gradle | grep -o "version '[0-9\\.]*'" | cut -d" " -f2 | sed "s/'//g")
|
||||||
cat metadata.json | jq --arg project "${PROJECT}" --arg version "${version}" '
|
jq --arg project "${PROJECT}" --arg version "${version}" '
|
||||||
.
|
.
|
||||||
| .changes |= map({"commit", "summary", "message"})
|
| .changes |= map({"commit", "summary", "message"})
|
||||||
| .downloads |= map_values({"name", "sha256"})
|
| .downloads |= map_values({"name", "sha256"})
|
||||||
| {$project, "repo", $version, "number": .build, "changes", "downloads"}
|
| {$project, "repo", $version, "number": .build, "changes", "downloads"}
|
||||||
' | tee metadata.json
|
' metadata.json.tmp > metadata.json
|
||||||
|
cat metadata.json
|
||||||
|
|
||||||
- name: Publish to Downloads API
|
- name: Publish to Downloads API
|
||||||
if: ${{ success() && github.repository == 'GeyserMC/GeyserConnect' && github.ref_name == 'master' }}
|
if: ${{ success() && github.repository == 'GeyserMC/GeyserConnect' && github.ref_name == 'master' }}
|
||||||
|
|
Loading…
Add table
Reference in a new issue