Skip to content

Commit 0d6e3b7

Browse files
authored
Modified to crate publishing method
1 parent c826bdb commit 0d6e3b7

File tree

1 file changed

+17
-16
lines changed

1 file changed

+17
-16
lines changed

.github/workflows/publish-upon-release.yml

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,24 @@ jobs:
1111
runs-on: ubuntu-latest
1212

1313
steps:
14-
- name: Check out code
15-
uses: actions/checkout@v2
16-
17-
- name: Set up Rust
18-
uses: actions/setup-rust@v2
14+
- uses: actions/checkout@v3
15+
- uses: actions-rs/toolchain@v1
1916
with:
2017
toolchain: stable
18+
override: true
2119

22-
- name: Install cargo-release
23-
run: cargo install cargo-release
24-
25-
- name: Dry-run publish to Crates.io (for llama-cpp-2)
26-
run: cargo release --dry-run
27-
env:
28-
CRATES_IO_TOKEN: ${{ secrets.CRATES_IO_TOKEN }}
20+
- name: Publish crates for llama-cpp-2
21+
uses: katyo/publish-crates@v2
22+
with:
23+
path: './llama-cpp-2'
24+
registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}
25+
args: --no-verify
26+
dry-run: true
2927

30-
- name: Dry-run publish to Crates.io (for llama-cpp-sys-2)
31-
run: cd llama-cpp-sys-2 && cargo release --dry-run
32-
env:
33-
CRATES_IO_TOKEN: ${{ secrets.CRATES_IO_TOKEN }}
28+
- name: Publish crates for llama-cpp-sys-2
29+
uses: katyo/publish-crates@v2
30+
with:
31+
path: './llama-cpp-sys-2'
32+
registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}
33+
args: --no-verify
34+
dry-run: true

0 commit comments

Comments
 (0)