ci: add size diff to release notes
This commit is contained in:
parent
3279282c96
commit
be076a2fe4
2 changed files with 10 additions and 1 deletions
3
.github/workflows/nightly.yml
vendored
3
.github/workflows/nightly.yml
vendored
|
@ -149,8 +149,9 @@ jobs:
|
||||||
git push origin --delete nightly || true
|
git push origin --delete nightly || true
|
||||||
git tag nightly
|
git tag nightly
|
||||||
git push origin nightly
|
git push origin nightly
|
||||||
|
curl -L -o old.asar "https://github.com/GooseMod/OpenAsar/releases/download/nightly/app.asar"
|
||||||
gh release delete ${{ env.VERSION }} -y || true
|
gh release delete ${{ env.VERSION }} -y || true
|
||||||
gh release create ${{ env.VERSION }} -t "Nightly" -n "$(git rev-parse HEAD | cut -c 1-7) | $(git log -1 --pretty=%B)" ${{ env.FILES }}
|
gh release create ${{ env.VERSION }} -t "Nightly" -n "$(bash scripts/nightlyNotes.sh)" ${{ env.FILES }}
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
|
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
|
||||||
VERSION: 'nightly'
|
VERSION: 'nightly'
|
||||||
|
|
8
scripts/nightlyNotes.sh
Normal file
8
scripts/nightlyNotes.sh
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
echo "$(git rev-parse HEAD | cut -c 1-7) | $(git log -1 --pretty=%B)"
|
||||||
|
|
||||||
|
size_old=$(stat -c "%s" old.asar)
|
||||||
|
size_new=$(stat -c "%s" app.asar)
|
||||||
|
|
||||||
|
echo "print(\"%+2.3f KB\" % (($size_new-$size_old)/1000))" | python3
|
Loading…
Reference in a new issue