| 1 |
name: Publish to crates.io |
| 2 |
|
| 3 |
on: |
| 4 |
release: |
| 5 |
types: [released] |
| 6 |
|
| 7 |
jobs: |
| 8 |
publish: |
| 9 |
runs-on: ubuntu-latest |
| 10 |
|
| 11 |
environment: publish |
| 12 |
permissions: |
| 13 |
id-token: write |
| 14 |
|
| 15 |
steps: |
| 16 |
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd |
| 17 |
with: |
| 18 |
persist-credentials: false |
| 19 |
|
| 20 |
- uses: rust-lang/crates-io-auth-action@bbd81622f20ce9e2dd9622e3218b975523e45bbe |
| 21 |
id: auth |
| 22 |
|
| 23 |
- name: Install dependencies |
| 24 |
run: | |
| 25 |
sudo apt update |
| 26 |
sudo apt install libpam0g-dev |
| 27 |
|
| 28 |
- run: cargo publish --locked |
| 29 |
env: |
| 30 |
CARGO_REGISTRY_TOKEN: ${{ steps.auth.outputs.token }} |