blob: f397410501d897a3ca0c1b2720c44140d35766fd [file] [edit]
name: package:trebuchet
permissions: read-all
on:
pull_request:
branches: [ main ]
paths:
- '.github/workflows/trebuchet.yml'
- 'pkgs/trebuchet/**'
push:
branches: [ main ]
paths:
- '.github/workflows/trebuchet.yml'
- 'pkgs/trebuchet/**'
schedule:
- cron: '0 0 * * 0' # weekly
defaults:
run:
working-directory: pkgs/trebuchet
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
sdk: [stable, dev]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1
- uses: dart-lang/setup-dart@6afc89df92d6eb3834022f73cd65adc8cdfcb92d
with:
sdk: ${{ matrix.sdk }}
- uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9
with:
path: ~/.pub-cache
key: ${{ runner.os }}-pub-cache-${{ hashFiles('**/pubspec.lock') }}
restore-keys: |
${{ runner.os }}-pub-cache-
- run: dart pub get
- run: dart analyze --fatal-infos
- run: dart format --output=none --set-exit-if-changed .
if: ${{ matrix.sdk == 'stable' }}