Add Pre-release (#448)

This commit is contained in:
bladeoner 2022-12-02 17:47:34 +01:00 committed by GitHub
parent d7b446447a
commit 61ba1ed3f3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,7 +4,7 @@ on: [push, pull_request]
jobs: jobs:
build: build:
name: Build VBA GX name: Build
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy: strategy:
matrix: matrix:
@ -59,3 +59,40 @@ jobs:
name: VisualBoyAdvanceGX-GameCube name: VisualBoyAdvanceGX-GameCube
path: | path: |
dist/VisualBoyAdvanceGX-GameCube/ dist/VisualBoyAdvanceGX-GameCube/
release:
name: Release
runs-on: ubuntu-latest
needs: [build]
if: github.ref == 'refs/heads/master'
steps:
- uses: actions/checkout@v3
name: Download Artifacts
- uses: actions/download-artifact@v3
with:
path: dist
- name: Re-zip artifacts
run: |
cd dist
rm -r VisualBoyAdvanceGX/vbagx/roms/*
rm -r VisualBoyAdvanceGX/vbagx/saves/*
zip -r VisualBoyAdvanceGX.zip VisualBoyAdvanceGX
zip -r VisualBoyAdvanceGX-GameCube.zip VisualBoyAdvanceGX-GameCube
- name: Update Git Tag
run: |
git tag -f Pre-release
git push -f origin Pre-release
- name: Create Release
uses: ncipollo/release-action@v1
with:
prerelease: true
allowUpdates: true
removeArtifacts: true
replacesArtifacts: false
tag: Pre-release
artifacts: "dist/*.zip"