Skip to content

Instantly share code, notes, and snippets.

@SteveOye
Last active February 3, 2023 17:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SteveOye/77d2d6727352db146b0462300d466f3a to your computer and use it in GitHub Desktop.
Save SteveOye/77d2d6727352db146b0462300d466f3a to your computer and use it in GitHub Desktop.
Github action
name: Flutter
on: #events (push and pull_request)
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs: #here we specify the jobs - We could have multiple jobs
build: #name it something meaningful
runs-on: macos-latest #runner: select a machine to use
//put down the steps
steps:
- uses: actions/checkout@v1
- uses: actions/setup-java@v1
with:
java-version: '12.x'
- uses: subosito/flutter-action@v1
with:
channel: 'stable'
- name: Install dependencies
run: flutter pub get # action
- name: Run tests
run: flutter test
- name: Build android apk and appBundle
run: flutter build apk
- name: Build android ios
run: flutter build ios --releasee --no-codesign
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment