Skip to content

Commit 58bc7d7

Browse files
committed
ci: fix cargo publish deprecation and allow re-runs
1 parent 4d57903 commit 58bc7d7

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

.github/workflows/publish.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,17 +153,21 @@ jobs:
153153
publish-crates:
154154
name: Publish to crates.io
155155
runs-on: ubuntu-latest
156+
env:
157+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
156158
steps:
157159
- uses: actions/checkout@v4
158160

159161
- name: Install Rust
160162
uses: dtolnay/rust-toolchain@stable
161163

162164
- name: Publish supermarkdown
163-
run: cargo publish -p supermarkdown --token ${{ secrets.CARGO_REGISTRY_TOKEN }}
165+
run: cargo publish -p supermarkdown || echo "Already published or failed"
166+
continue-on-error: true
164167

165168
- name: Wait for crates.io to index
166169
run: sleep 30
167170

168171
- name: Publish supermarkdown-cli
169-
run: cargo publish -p supermarkdown-cli --token ${{ secrets.CARGO_REGISTRY_TOKEN }}
172+
run: cargo publish -p supermarkdown-cli || echo "Already published or failed"
173+
continue-on-error: true

0 commit comments

Comments
 (0)