-
-
Notifications
You must be signed in to change notification settings - Fork 232
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Move to package structure and introduce Melos (#282)
- Loading branch information
Showing
135 changed files
with
1,669 additions
and
1,475 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
name: Build Flutter Beta | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- flutter-beta | ||
|
@@ -15,20 +16,24 @@ concurrency: | |
jobs: | ||
quality: | ||
name: Quality Checks | ||
runs-on: ubuntu-latest | ||
runs-on: macos-14 | ||
defaults: | ||
run: | ||
working-directory: packages/home_widget | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: beta | ||
- name: Get Packages | ||
run: flutter pub get | ||
- uses: bluefireteam/melos-action@v3 | ||
- name: Analyze | ||
run: flutter analyze | ||
run: melos analyze | ||
- name: Install Formatters | ||
run: brew install swift-format ktfmt | ||
- name: Format | ||
run: dart format . --set-exit-if-changed | ||
run: melos format:all | ||
- name: Publishability | ||
run: flutter pub publish --dry-run | ||
- name: Test | ||
|
@@ -45,18 +50,18 @@ jobs: | |
uses: codecov/codecov-action@v1 | ||
with: | ||
token: ${{ secrets.CODECOV_TOKEN }} | ||
- uses: VeryGoodOpenSource/[email protected] | ||
path: ./packages/home_widget/coverage/lcov.info | ||
|
||
android: | ||
name: Android Integration Tests | ||
needs: quality | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: beta | ||
- uses: bluefireteam/melos-action@v3 | ||
- name: Enable KVM | ||
run: | | ||
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules | ||
|
@@ -71,20 +76,22 @@ jobs: | |
uses: reactivecircus/android-emulator-runner@v2 | ||
with: | ||
api-level: 29 | ||
working-directory: example | ||
script: flutter test integration_test/android_test.dart -d emulator-5554 | ||
working-directory: packages/home_widget/example | ||
|
||
# iOS Test based on https://medium.com/flutter-community/run-flutter-driver-tests-on-github-actions-13c639c7e4ab | ||
# by @kate_sheremet | ||
ios: | ||
name: iOS Integration Tests | ||
needs: quality | ||
strategy: | ||
matrix: | ||
device: | ||
- "iPhone 14" | ||
fail-fast: false | ||
runs-on: macos-14 | ||
defaults: | ||
run: | ||
working-directory: packages/home_widget/example | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: maxim-lobanov/setup-xcode@v1 | ||
|
@@ -93,10 +100,10 @@ jobs: | |
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: beta | ||
- uses: bluefireteam/melos-action@v3 | ||
- uses: futureware-tech/simulator-action@v1 | ||
id: simulator | ||
with: | ||
model: ${{ matrix.device }} | ||
- name: "Run iOS integration tests" | ||
run: flutter test integration_test/ios_test.dart -d ${{steps.simulator.outputs.udid}} | ||
working-directory: example | ||
run: flutter test integration_test/ios_test.dart -d ${{steps.simulator.outputs.udid}} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
name: Build | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
|
@@ -17,20 +18,24 @@ concurrency: | |
jobs: | ||
quality: | ||
name: Quality Checks | ||
runs-on: ubuntu-latest | ||
runs-on: macos-14 | ||
defaults: | ||
run: | ||
working-directory: packages/home_widget | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: stable | ||
- name: Get Packages | ||
run: flutter pub get | ||
- uses: bluefireteam/melos-action@v3 | ||
- name: Analyze | ||
run: flutter analyze | ||
run: melos analyze | ||
- name: Install Formatters | ||
run: brew install swift-format ktfmt | ||
- name: Format | ||
run: dart format . --set-exit-if-changed | ||
run: melos format:all | ||
- name: Publishability | ||
run: flutter pub publish --dry-run | ||
- name: Test | ||
|
@@ -47,18 +52,18 @@ jobs: | |
uses: codecov/codecov-action@v1 | ||
with: | ||
token: ${{ secrets.CODECOV_TOKEN }} | ||
- uses: VeryGoodOpenSource/[email protected] | ||
path: ./packages/home_widget/coverage/lcov.info | ||
|
||
android: | ||
name: Android Integration Tests | ||
needs: quality | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: stable | ||
- uses: bluefireteam/melos-action@v3 | ||
- name: Enable KVM | ||
run: | | ||
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules | ||
|
@@ -73,20 +78,22 @@ jobs: | |
uses: reactivecircus/android-emulator-runner@v2 | ||
with: | ||
api-level: 29 | ||
working-directory: example | ||
script: flutter test integration_test/android_test.dart -d emulator-5554 | ||
working-directory: packages/home_widget/example | ||
|
||
# iOS Test based on https://medium.com/flutter-community/run-flutter-driver-tests-on-github-actions-13c639c7e4ab | ||
# by @kate_sheremet | ||
ios: | ||
name: iOS Integration Tests | ||
needs: quality | ||
strategy: | ||
matrix: | ||
device: | ||
- "iPhone 14" | ||
fail-fast: false | ||
runs-on: macos-14 | ||
defaults: | ||
run: | ||
working-directory: packages/home_widget/example | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: maxim-lobanov/setup-xcode@v1 | ||
|
@@ -95,10 +102,10 @@ jobs: | |
- uses: subosito/flutter-action@v1 | ||
with: | ||
channel: stable | ||
- uses: bluefireteam/melos-action@v3 | ||
- uses: futureware-tech/simulator-action@v1 | ||
id: simulator | ||
with: | ||
model: ${{ matrix.device }} | ||
- name: "Run iOS integration tests" | ||
run: flutter test integration_test/ios_test.dart -d ${{steps.simulator.outputs.udid}} | ||
working-directory: example | ||
run: flutter test integration_test/ios_test.dart -d ${{steps.simulator.outputs.udid}} |
Oops, something went wrong.