Skip to content

Commit

Permalink
ci: create draft release
Browse files Browse the repository at this point in the history
  • Loading branch information
Rosalie241 committed Jan 4, 2024
1 parent 82f2f6c commit aed6b51
Showing 1 changed file with 36 additions and 1 deletion.
37 changes: 36 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -186,4 +186,39 @@ jobs:
- name: Test SporeModManager (mingw)
run: |
python3 ./SporeModManager/test.py ./artifact/SporeModLoader/SporeModManager/SporeModManager.exe
# actions/upload-artifact still doesn't retain
# file permissions, so we'll need to download
# the artifact, mark the linux executable as
# executable, then add it to a draft release
# TODO: remove this whenever github actions
# will retain file permissions properly
create-draft-release:
runs-on: ubuntu-20.04
needs: [ msvc-test, linux-test, mingw-test ]
#if: github.ref_type == 'tag'
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Prepare Environment
run: |
echo "GIT_REVISION=$(git describe --tags --always)" >> $GITHUB_ENV
- name: Download SporeModManager (msvc)
uses: actions/download-artifact@v4
with:
name: SporeModLoader-${{ env.GIT_REVISION }}
path: artifact
- name: Prepare SporeModManager (msvc)
run: |
pushd artifact
chmod +x SporeModLoader/SporeModManager/SporeModManager
zip -9 -r "../SporeModLoader-${GIT_REVISION}.zip" *
popd
- name: Create Draft Release
uses: ncipollo/[email protected]
with:
draft: true
makeLatest: true
#tag: ${{ env.GIT_REVISION }}
tag: v3.1.4 # TODO: remove
artifacts: SporeModLoader-${GIT_REVISION}.zip

0 comments on commit aed6b51

Please sign in to comment.