Skip to content

Refactor

Refactor #3

Workflow file for this run

name: Release
on:
push:
tags:
- "v*.*.*"
jobs:
wait:
name: Wait for successful tests
runs-on: ubuntu-latest
steps:
- name: Wait for tests
uses: lewagon/wait-on-check-action@v1.3.3
with:
ref: ${{ github.sha }}
check-name: 'Test'
repo-token: ${{ secrets.GITHUB_TOKEN }}
build:
name: Build for ${{ fromJSON(matrix.build).os }}
needs: [ wait ]
runs-on: ${{fromJSON(matrix.build).os}}
strategy:
matrix:
build: [ '{"os": "windows-latest", "exe": "dage-windows-amd64.exe"}', '{"os": "ubuntu-latest", "exe": "dage-linux-amd64"}', '{"os": "macos-latest", "exe": "dage-darwin-amd64"}' ]
steps:
- uses: actions/checkout@v4
- uses: dart-lang/setup-dart@v1
- name: Install dependencies
run: dart pub get
- name: Compile
run: dart compile exe bin/dage.dart -o bin/${{fromJSON(matrix.build).exe}}
- name: Upload artifact for ${{ fromJSON(matrix.build).os }}
uses: actions/upload-artifact@v4
with:
name: ${{fromJSON(matrix.build).exe}}
path: bin/${{fromJSON(matrix.build).exe}}
release:
name: 'Release'
needs: [ build ]
runs-on: ubuntu-latest
steps:
- name: Download artifacts
uses: actions/download-artifact@v4
with:
pattern: dage-*
- name: Release
uses: softprops/action-gh-release@v1
with:
files: dage-*