Skip to content

Commit f1c1281

Browse files
authored
ci: trigger cargo publish from release workflow (#103)
GITHUB_TOKEN-created releases don't fire on:release triggers, so dispatch cargo-publish.yml directly from release.yml (same pattern as GHCR image publish). Signed-off-by: danbugs <danilochiarlone@gmail.com>
1 parent 682ad20 commit f1c1281

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

.github/workflows/cargo-publish.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
name: Publish to crates.io
22

33
on:
4-
release:
5-
types: [published]
64
workflow_dispatch:
75
inputs:
86
dry_run:

.github/workflows/release.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,3 +56,10 @@ jobs:
5656
run: |
5757
VERSION="${{ steps.version.outputs.version }}"
5858
gh workflow run publish-examples.yml --ref "v$VERSION"
59+
60+
- name: Trigger crates.io publish
61+
env:
62+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
63+
run: |
64+
VERSION="${{ steps.version.outputs.version }}"
65+
gh workflow run cargo-publish.yml --ref "v$VERSION" -f dry_run=false

0 commit comments

Comments
 (0)