Skip to content

Commit 3c6c9d3

Browse files
committed
ci: fix publish crates
1 parent 33f96e4 commit 3c6c9d3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

.github/workflows/publish-crates.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: publish crates
1+
name: "publish crates"
22
on:
33
push:
44
branches: ["**"]
@@ -9,6 +9,7 @@ permissions: {}
99

1010
jobs:
1111
set-up:
12+
if: ${{ !( github.workflow == 'publish crates' && startsWith(github.event.head_commit.message, 'release:') && github.event.head_commit.author.name == 'github-actions[bot]' ) }}
1213
runs-on: ubuntu-latest
1314
permissions: {}
1415
outputs:
@@ -19,9 +20,8 @@ jobs:
1920
DRY_RUN: ${{ github.workflow == 'publish crates' }}
2021
run: echo "dry-run=$DRY_RUN" >> $GITHUB_OUTPUT
2122
publish:
22-
if: ${{ !( github.workflow == 'crates publish' && startsWith(github.event.head_commit.message, 'release:') && github.event.head_commit.author.name == 'github-actions[bot]' ) }}
2323
needs: ["set-up"]
24-
name: "${{ needs.set-up.outputs.dry-run && 'DRY-RUN' || '' }} publish"
24+
name: "${{ fromJson(needs.set-up.outputs.dry-run) && 'DRY-RUN' || '' }} publish"
2525
runs-on: ubuntu-latest
2626
permissions: {}
2727
steps:
@@ -32,5 +32,5 @@ jobs:
3232
- uses: katyo/publish-crates@33e1d18666cdfacf9f6c3547194d2c1d39cbf849 # v2
3333
with:
3434
registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}
35-
dry-run: ${{ true || needs.set-up.outputs.dry-run }}
35+
dry-run: ${{ true || fromJson(needs.set-up.outputs.dry-run) }}
3636
ignore-unpublished-changes: true

0 commit comments

Comments
 (0)