-
Notifications
You must be signed in to change notification settings - Fork 2
31 lines (29 loc) · 986 Bytes
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
name: Publish to pub.dev
on:
push:
tags:
- "[0-9]+.[0-9]+.[0-9]+"
# workflow_run:
# workflows: [Set package version]
# types:
# - completed
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write # Required for authentication using OIDC
# uses: dart-lang/setup-dart/.github/workflows/publish.yml@v1
# we'd prefer the reusable workflow, but
# but it is broken for flutter packages: https://github.com/dart-lang/setup-dart/issues/68
# uses: dart-lang/setup-dart/.github/workflows/publish.yml@v1
steps:
- uses: actions/checkout@v4
- uses: dart-lang/setup-dart@b64355ae6ca0b5d484f0106a033dd1388965d06d
- uses: subosito/flutter-action@2783a3f08e1baf891508463f8c6653c258246225
- name: Install dependencies
run: dart pub get
- name: Publish - dry run
run: dart pub publish --dry-run
- name: Publish to pub.dev
run: dart pub publish -f