Skip to content

Commit 7157e1f

Browse files
committed
Add an action to publish the grammar automatically
1 parent f7fb205 commit 7157e1f

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

.github/workflows/publish_crate.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Publish on crates.io
2+
3+
on:
4+
push:
5+
tags:
6+
- v*
7+
8+
env:
9+
CARGO_TERM_COLOR: always
10+
CARGO_INCREMENTAL: 0
11+
12+
jobs:
13+
publish:
14+
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- name: Checkout repository
19+
uses: actions/checkout@v3
20+
21+
- name: Install Rust stable
22+
run: |
23+
rustup toolchain install stable --profile minimal --no-self-update
24+
25+
- name: Verify publish crate
26+
uses: katyo/publish-crates@v1
27+
with:
28+
dry-run: true
29+
30+
- name: Publish crate
31+
uses: katyo/publish-crates@v1
32+
with:
33+
registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}

0 commit comments

Comments
 (0)