Skip to content

Commit 567f8a7

Browse files
committed
ci: add workflow for publishing
Signed-off-by: Shengqi Chen <harry-chen@outlook.com>
1 parent 55489ad commit 567f8a7

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

.github/workflows/publish.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Publish to pub.dev
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v[0-9]+.[0-9]+.[0-9]+*'
7+
8+
jobs:
9+
publish:
10+
name: 'Publish to pub.dev'
11+
permissions:
12+
id-token: write
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v4
16+
- uses: dart-lang/setup-dart@v1
17+
- name: Install dependencies
18+
run: dart pub get
19+
- name: Publish - dry run
20+
run: dart pub publish --dry-run
21+
- name: Publish to pub.dev
22+
run: dart pub publish -f

0 commit comments

Comments
 (0)