mirror of
https://github.com/flutter/samples.git
synced 2025-11-08 13:58:47 +00:00
Replaces Travis CI with GitHub Actions (#625)
This commit is contained in:
60
.github/workflows/main.yml
vendored
Normal file
60
.github/workflows/main.yml
vendored
Normal file
@@ -0,0 +1,60 @@
|
||||
name: Flutter CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master ]
|
||||
pull_request:
|
||||
branches: [ master ]
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 0 * * *' # Every day at midnight
|
||||
|
||||
jobs:
|
||||
flutter-tests:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- flutter_version: dev
|
||||
allow_failure: true
|
||||
- flutter_version: beta
|
||||
allow_failure: true
|
||||
- flutter_version: stable
|
||||
allow_failure: false
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '12.x'
|
||||
- uses: subosito/flutter-action@v1
|
||||
with:
|
||||
channel: ${{ matrix.flutter_version }}
|
||||
- run: ./tool/flutter_ci_script.sh
|
||||
continue-on-error: ${{ matrix.allow_failure }}
|
||||
android-build:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '12.x'
|
||||
- uses: subosito/flutter-action@v1
|
||||
with:
|
||||
channel: stable
|
||||
- run: ./tool/android_ci_script.sh
|
||||
ios-build:
|
||||
runs-on: macos-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '12.x'
|
||||
- uses: subosito/flutter-action@v1
|
||||
with:
|
||||
channel: stable
|
||||
- run: ./tool/ios_ci_script.sh
|
||||
Reference in New Issue
Block a user