Added automatic publishing to crates.io on publish (#8263)

* Added automatic publishing to crates.io on publish

* Fixed indentation

* Update release.yml

Change secret name.

* Update release.yml

remove extra space added in merge

---------

Co-authored-by: Derek Bailey <derekbailey@google.com>
This commit is contained in:
Ricardo Delfin 2024-05-29 02:19:41 +01:00 committed by GitHub
parent 5adfac9fc3
commit 5ba66f71c5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 16 additions and 1 deletions

View File

@ -109,7 +109,6 @@ jobs:
working-directory: ./kotlin
steps:
- uses: actions/checkout@v3
- name: Set up Maven Central Repository
uses: actions/setup-java@v3
with:
@ -129,3 +128,19 @@ jobs:
OSSRH_PASSWORD: ${{ secrets.OSSRH_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
publish-crates:
name: Publish crates.io
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./rust
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- uses: katyo/publish-crates@v2
with:
registry-token: ${{ secrets.CARGO_TOKEN }}