Skip to content

Commit

Permalink
simplify the workflow for package:graphs
Browse files Browse the repository at this point in the history
  • Loading branch information
devoncarew committed Nov 7, 2024
1 parent d6a2d0c commit 6eeaba9
Showing 1 changed file with 15 additions and 38 deletions.
53 changes: 15 additions & 38 deletions .github/workflows/graphs.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
name: package:graphs

permissions: read-all

on:
# Run on PRs and pushes to the default branch.
# Run CI on pushes to the main branch, and on PRs against main.
push:
branches: [ main ]
paths:
Expand All @@ -14,54 +15,30 @@ on:
- '.github/workflows/graphs.yml'
- 'pkgs/graphs/**'
schedule:
- cron: "0 0 * * 0"
- cron: '0 0 * * 0' # weekly

env:
PUB_ENVIRONMENT: bot.github
defaults:
run:
working-directory: pkgs/graphs

jobs:
# Check code formatting and static analysis on a single OS (linux)
# against Dart beta.
analyze:
build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: pkgs/graphs/
strategy:
fail-fast: false
matrix:
sdk: [dev]
sdk: [stable, dev]
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- uses: dart-lang/setup-dart@0a8a0fc875eb934c15d08629302413c671d3f672
with:
sdk: ${{ matrix.sdk }}
- id: install
run: dart pub get
- run: dart format --output=none --set-exit-if-changed .
if: always() && steps.install.outcome == 'success'

- run: dart pub get

- run: dart analyze --fatal-infos
if: always() && steps.install.outcome == 'success'

test:
needs: analyze
runs-on: ${{ matrix.os }}
defaults:
run:
working-directory: pkgs/graphs/
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
sdk: [3.4, dev]
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- uses: dart-lang/setup-dart@0a8a0fc875eb934c15d08629302413c671d3f672
with:
sdk: ${{ matrix.sdk }}
- id: install
run: dart pub get
- run: dart test --platform vm
if: always() && steps.install.outcome == 'success'
- run: dart test --platform chrome
if: always() && steps.install.outcome == 'success'
- run: dart format --output=none --set-exit-if-changed .
if: ${{ matrix.sdk == 'stable' }}

- run: dart test

0 comments on commit 6eeaba9

Please sign in to comment.