v2 merge to dev #40
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build Anima | |
| on: | |
| push: | |
| branches: | |
| - dev | |
| - main | |
| env: | |
| TAG: v1.2.0-beta3 | |
| PRERELEASE: true | |
| jobs: | |
| build-windows: | |
| runs-on: windows-latest | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - run: npm install | |
| - run: npm run dist:win -- --publish never | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: windows-builds | |
| path: dist/Anima-v*/*.exe | |
| build-linux: | |
| runs-on: ubuntu-latest | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - run: npm install | |
| - run: npm run dist:linux -- --publish never | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: linux-builds | |
| path: dist/Anima-v*/*.AppImage | |
| release: | |
| needs: [build-windows, build-linux] | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| path: artifacts | |
| merge-multiple: true | |
| - name: Create or update release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| tag_name: ${{ env.TAG }} | |
| name: ${{ env.PRERELEASE == 'true' && format('Pre-release {0}', env.TAG) || format('Release {0}', env.TAG) }} | |
| prerelease: ${{ env.PRERELEASE == 'true' }} | |
| target_commitish: ${{ env.PRERELEASE == 'true' && 'dev' || 'main' }} | |
| body_path: CHANGELOG.md | |
| files: artifacts/**/* | |
| fail_on_unmatched_files: false |