Skip to content

Commit 630d7b5

Browse files
authored
fix(releaze-plz): trusted publishing token (#579)
1 parent a312cd2 commit 630d7b5

File tree

2 files changed

+5
-21
lines changed

2 files changed

+5
-21
lines changed

.github/workflows/build.yml

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -226,21 +226,3 @@ jobs:
226226
227227
- name: Test with embed feature
228228
run: cargo test --workspace --release --features closure,embed,anyhow --no-fail-fast
229-
230-
trigger-release-plz:
231-
name: Trigger Release Workflow
232-
runs-on: ubuntu-latest
233-
needs: [lint, build, test-embed]
234-
if: github.ref == 'refs/heads/master' && github.event_name == 'push'
235-
steps:
236-
- name: Trigger release-plz workflow
237-
uses: actions/github-script@v8
238-
with:
239-
github-token: ${{ secrets.GITHUB_TOKEN }}
240-
script: |
241-
await github.rest.actions.createWorkflowDispatch({
242-
owner: context.repo.owner,
243-
repo: context.repo.repo,
244-
workflow_id: 'release-plz.yml',
245-
ref: 'master'
246-
});

.github/workflows/release-plz.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,11 @@ permissions:
55
contents: write
66

77
on:
8-
workflow_dispatch:
8+
workflow_run:
9+
workflows: ["Build and Lint"]
10+
branches: ["master"]
11+
types:
12+
- completed
913

1014
jobs:
1115
release-plz-release:
@@ -56,7 +60,6 @@ jobs:
5660
command: release
5761
env:
5862
GITHUB_TOKEN: ${{ secrets.RELEASE_PLZ_TOKEN }}
59-
CARGO_REGISTRY_TOKEN: ${{ steps.auth.outputs.token }}
6063

6164
release-plz-pr:
6265
name: Release-plz PR
@@ -82,4 +85,3 @@ jobs:
8285
command: release-pr
8386
env:
8487
GITHUB_TOKEN: ${{ secrets.RELEASE_PLZ_TOKEN }}
85-
CARGO_REGISTRY_TOKEN: ${{ steps.auth.outputs.token }}

0 commit comments

Comments
 (0)