Merge pull request #16 from kosukesaigusa/ci/fix_publish_workflow_2 #3
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://dart.dev/tools/pub/automated-publishing#publishing-packages-using-github-actions | |
name: Publish to pub.dev | |
on: | |
push: | |
tags: | |
- 'flutterfire_gen-v[0-9]+.[0-9]+.[0-9]+*' | |
- 'flutterfire_gen_annotation-v[0-9]+.[0-9]+.[0-9]+*' | |
- 'flutterfire_gen_utils-v[0-9]+.[0-9]+.[0-9]+*' | |
jobs: | |
publish_flutterfire_gen: | |
if: startsWith(github.ref, 'refs/tags/flutterfire_gen-v') | |
permissions: | |
id-token: write | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: dart-lang/setup-dart@v1 | |
- uses: subosito/flutter-action@v2 | |
with: | |
channel: 'stable' | |
- name: Publish flutterfire_gen | |
run: | | |
cd packages/flutterfire_gen | |
flutter pub publish --force | |
publish_flutterfire_gen_annotation: | |
if: startsWith(github.ref, 'refs/tags/flutterfire_gen_annotation-v') | |
permissions: | |
id-token: write | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: dart-lang/setup-dart@v1 | |
- name: Publish flutterfire_gen_annotation | |
run: | | |
cd packages/flutterfire_gen_annotation | |
flutter pub publish --force | |
publish_flutterfire_gen_utils: | |
if: startsWith(github.ref, 'refs/tags/flutterfire_gen_utils-v') | |
permissions: | |
id-token: write | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: dart-lang/setup-dart@v1 | |
- name: Publish flutterfire_gen_utils | |
run: | | |
cd packages/flutterfire_gen_utils | |
flutter pub publish --force |