Skip to content

Commit

Permalink
Refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
v3rm0n committed Feb 3, 2024
1 parent db343a0 commit e78e48e
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 42 deletions.
34 changes: 0 additions & 34 deletions .github/workflows/artifacts.yml

This file was deleted.

34 changes: 26 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,40 @@ on:
- "v*.*.*"

jobs:
release:
name: 'Release'
wait:
name: Wait for successful tests
runs-on: ubuntu-latest
steps:
- name: Wait for artifacts
uses: lewagon/wait-on-check-action@v1.3.3
with:
ref: ${{ github.sha }}
check-name: 'Artifacts uploaded'
repo-token: ${{ secrets.GITHUB_TOKEN }}
- 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:
Expand Down

0 comments on commit e78e48e

Please sign in to comment.