Skip to content

Commit 43ca581

Browse files
committed
ci: add oidc
1 parent 9660787 commit 43ca581

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

.github/workflows/cd.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
name: Publish to Pub.dev & Github
22
on:
3+
workflow_dispatch:
34
pull_request:
45
types:
56
- closed
67
branches:
78
- main
89
- rel/**
910

11+
permissions:
12+
id-token: write # Required for authentication using OIDC
13+
contents: write
14+
1015
jobs:
1116
publish:
1217
if: |
13-
github.event.pull_request.merged == true &&
14-
contains(github.event.pull_request.title, 'chore: Release')
18+
github.event_name == 'workflow_dispatch' ||
19+
(github.event.pull_request.merged == true &&
20+
contains(github.event.pull_request.title, 'chore: Release'))
1521
runs-on: ubuntu-latest
1622
outputs:
1723
version: ${{ steps.version.outputs.version }}

0 commit comments

Comments
 (0)