We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 6d47f54 + a2ca59b commit 797bb46Copy full SHA for 797bb46
1 file changed
.github/workflows/publish.yml
@@ -0,0 +1,27 @@
1
+# .github/workflows/publish.yml
2
+name: Publish to pub.dev
3
+
4
+on:
5
+ push:
6
+ tags:
7
+ - 'v[0-9]+.[0-9]+.[0-9]+' # must match tag pattern on pub.dev (e.g. 'v{{version}}')
8
+ workflow_dispatch: # manual trigger: runs dry-run only (pub.dev accepts publish only on tag push)
9
10
+jobs:
11
+ publish:
12
+ permissions:
13
+ id-token: write # Required for OIDC authentication
14
+ name: 'Publish to pub.dev'
15
+ environment: 'pub.dev'
16
+ runs-on: ubuntu-latest
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+ - uses: dart-lang/setup-dart@v1
20
+ with:
21
+ sdk: stable
22
+ - name: Install dependencies
23
+ run: dart pub get
24
+ - name: Test Publish (Dry Run)
25
+ run: dart pub publish --dry-run
26
+ - name: Publish
27
+ run: dart pub publish --force
0 commit comments