antares/.github/workflows/build.yml

50 lines
1.1 KiB
YAML
Raw Normal View History

2023-07-31 10:55:05 +02:00
name: Build & release [STABLE]
2022-08-02 10:10:20 +02:00
on:
push:
tags:
2023-07-31 13:04:30 +02:00
- 'v[0-9]+.[0-9]+.[0-9]+'
2023-07-31 10:55:05 +02:00
env:
2023-07-31 13:04:30 +02:00
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
2022-08-02 10:10:20 +02:00
jobs:
release:
runs-on: ${{ matrix.os }}
strategy:
2023-11-14 14:36:31 +01:00
fail-fast: false
2022-08-02 10:10:20 +02:00
matrix:
2023-11-16 18:01:40 +01:00
os: [macos-latest, ubuntu-latest, windows-latest]
2022-08-02 10:10:20 +02:00
steps:
2023-07-31 10:55:05 +02:00
- name: Exit if not on master branch
if: contains(env.BRANCH_NAME, 'master') == false
run: |
echo "Wrong environment ${{env.BRANCH_NAME}}"
exit 0
2022-08-02 10:10:20 +02:00
- name: Check out Git repository
uses: actions/checkout@v3
2023-07-31 13:04:30 +02:00
with:
ref: master
2022-08-02 10:10:20 +02:00
- name: Install Node.js
uses: actions/setup-node@v3
with:
2023-11-16 18:01:40 +01:00
node-version: 20
2022-08-02 10:10:20 +02:00
- name: Install dependencies
run: npm i
- name: "Build"
2022-08-02 10:37:27 +02:00
run: npm run build
2022-08-02 10:10:20 +02:00
- name: Release
uses: ncipollo/release-action@v1
with:
artifacts: "build/*.AppImage,build/*.yml,build/*.deb,build/*.dmg,build/*.blockmap,build/*.zip,build/*.exe"
allowUpdates: true
draft: true
generateReleaseNotes: true