Skip to content

Commit 2c6cf33

Browse files
authored
Add release workflow (#45)
1 parent e0c3f69 commit 2c6cf33

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

.github/workflows/release.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Publish Release
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
publish:
9+
name: Publish crate
10+
runs-on: ubuntu-latest
11+
timeout-minutes: 60
12+
env:
13+
RUSTFLAGS: -D warnings
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
- name: Install Rust toolchain
18+
uses: dtolnay/rust-toolchain@stable
19+
- name: Package (dry-run)
20+
run: cargo package
21+
- name: Publish
22+
env:
23+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
24+
PATCH: ${{ github.run_number }}
25+
shell: bash
26+
run: |
27+
git config --global user.email "[email protected]"
28+
git config --global user.name "Github Action"
29+
cargo publish

0 commit comments

Comments
 (0)