Skip to content

Publish

Publish #4

Workflow file for this run

name: Publish
on:
push:
tags:
- '*'
jobs:
check:
name: Run checks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
cache: true
channel: stable
- name: Install Tools
run: flutter pub global activate melos
- name: Bootstrap Workspace
run: melos bootstrap
- name: Install dependencies
run: melos get
- name: Run tests
run: melos test --no-select
publish-insights:
if: ${{ contains(github.ref, 'insights') }}
needs:
- check
permissions:
id-token: write
uses: dart-lang/setup-dart/.github/workflows/publish.yml@v1
with:
working-directory: insights
# Helps insights get published first to prevent
# the helper being penalized by pub.dev's scoring system
delay-publish-helper:
if: ${{ contains(github.ref, 'helper') }}
runs-on: ubuntu-latest
needs:
- check
steps:
- name: Wait for 30 seconds
run: sleep 30s
shell: bash
publish-helper:
if: ${{ contains(github.ref, 'helper') }}
needs:
- check
- delay-publish-helper
permissions:
id-token: write
uses: dart-lang/setup-dart/.github/workflows/publish.yml@v1
with:
working-directory: helper