Skip to content

Commit 1695481

Browse files
ci: expose CARGO_REGISTRY_TOKEN as global env variable to simplify cargo publish
1 parent 9ccc229 commit 1695481

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

.github/workflows/rust-build.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ on:
4141

4242
env:
4343
CARGO_TERM_COLOR: always
44+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
4445

4546
jobs:
4647
build:
@@ -113,4 +114,4 @@ jobs:
113114
run: cargo package
114115

115116
- name: Publish to crates.io
116-
run: cargo publish --token ${{ secrets.CARGO_REGISTRY_TOKEN }}
117+
run: cargo publish

0 commit comments

Comments
 (0)