Skip to content

Update CHANGELOG, README and version number #7

Update CHANGELOG, README and version number

Update CHANGELOG, README and version number #7

Workflow file for this run

name: Build the package
on:
workflow_dispatch:
push:
branches:
- main
- dev
pull_request:
branches:
- main
- dev
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
# This is Dart 3.0.x
FLUTTER_MIN_SDK: '3.10.6'
jobs:
format:
name: "Check formatting"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
cache: true
- run: dart format --set-exit-if-changed .
- run: dart format --set-exit-if-changed example
lint:
name: "Check linting"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
cache: true
- run: flutter pub get
- run: flutter analyze
- run: flutter pub get
working-directory: example
- run: flutter analyze
working-directory: example
build-android:
name: "Build Android example"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# The example Android project setup ist not supported by Flutter 3.10.x
sdk: [ stable, beta ]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
cache: 'gradle'
- uses: subosito/flutter-action@v2
with:
cache: true
flutter-version: ${{ matrix.sdk == 'min' && env.FLUTTER_MIN_SDK || '' }}
channel: ${{ matrix.sdk == 'min' && 'stable' || matrix.sdk }}
- name: Build example APK
working-directory: example
run: flutter build apk
- name: Upload apk as artifact
uses: actions/upload-artifact@v4
if: ${{ matrix.sdk == 'stable' }}
with:
name: background-downloader-demo.apk
path: example/build/app/outputs/flutter-apk/app-release.apk
build-ios:
name: "Build iOS example"
runs-on: macos-latest
strategy:
fail-fast: false
matrix:
sdk: [ min, stable, beta ]
steps:
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
cache: true
flutter-version: ${{ matrix.sdk == 'min' && env.FLUTTER_MIN_SDK || '' }}
channel: ${{ matrix.sdk == 'min' && 'stable' || matrix.sdk }}
- uses: maxim-lobanov/setup-cocoapods@v1
with:
version: latest
- name: Build example iOS package
run: flutter build ios --simulator
working-directory: example
- name: Upload Runner.app as artifact
if: ${{ matrix.sdk == 'stable' }}
uses: actions/upload-artifact@v4
with:
name: background-downloader-demo.app
path: example/build/ios/iphonesimulator
build-linux:
name: "Build Linux example"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
sdk: [ stable, beta ]
steps:
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
cache: true
flutter-version: ${{ matrix.sdk == 'min' && env.FLUTTER_MIN_SDK || '' }}
channel: ${{ matrix.sdk == 'min' && 'stable' || matrix.sdk }}
- run: flutter config --enable-linux-desktop
- name: Build example Linux package
run: flutter build linux
working-directory: example
- name: Upload example Linux package as artifact
if: ${{ matrix.sdk == 'stable' }}
uses: actions/upload-artifact@v4
with:
name: background-downloader-demo-linux
path: example/build/linux/x64/release/bundle