Skip to content

Commit

Permalink
wip: Update workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
lijy91 committed Mar 30, 2024
1 parent 70c944e commit 96af23a
Show file tree
Hide file tree
Showing 3 changed files with 76 additions and 19 deletions.
54 changes: 48 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,63 @@ name: build

on:
push:
branches: [main]
branches: [main, dev]
pull_request:
branches: [main]

jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
flutter-version: "3.19.2"
channel: "stable"
- run: |
sudo apt-get update
sudo apt-get install -y clang cmake ninja-build pkg-config libgtk-3-dev liblzma-dev
sudo apt-get install -y keybinder-3.0
- uses: bluefireteam/melos-action@v3
- working-directory: ./packages/auto_updater/example
run: |
flutter build linux --release
build-macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
- run: flutter config --enable-macos-desktop
- run: cd example && flutter build macos -v
with:
flutter-version: "3.19.2"
channel: "stable"
- uses: bluefireteam/melos-action@v3
- working-directory: ./packages/auto_updater/example
run: |
flutter build macos --release
build-web:
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
flutter-version: "3.19.2"
channel: "stable"
- uses: bluefireteam/melos-action@v3
- working-directory: ./packages/auto_updater/example
run: |
flutter build web --release
build-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
- run: cd example && flutter build windows -v
with:
flutter-version: "3.19.2"
channel: "stable"
- uses: bluefireteam/melos-action@v3
- working-directory: ./packages/auto_updater/example
run: |
flutter build windows --release
21 changes: 8 additions & 13 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: lint

on:
push:
branches: [main]
branches: [main, dev]
pull_request:
branches: [main]

Expand All @@ -13,24 +13,19 @@ jobs:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
flutter-version: "3.19.2"
channel: "stable"
- run: flutter analyze --fatal-infos
- uses: bluefireteam/melos-action@v3
- run: melos run analyze

format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
flutter-version: "3.19.2"
channel: "stable"
- run: dart format . --fix --set-exit-if-changed

dependency_validator:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
channel: "stable"
- run: flutter pub get
- run: flutter pub run dependency_validator
cache: true
- uses: bluefireteam/melos-action@v3
- run: melos run format-check
20 changes: 20 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: test

on:
push:
branches: [main, dev]
pull_request:
branches: [main]

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
flutter-version: "3.19.2"
channel: "stable"
cache: true
- uses: bluefireteam/melos-action@v3
- run: melos run test --no-select

0 comments on commit 96af23a

Please sign in to comment.