name: Release CI
on:
workflow_dispatch:
push:
tags:
- "v*"
env:
CARGO_TERM_COLOR: always
jobs:
release:
runs-on: ubuntu-latest
env:
SCCACHE_GHA_ENABLED: "true"
SCCACHE_CACHE_SIZE: 2G
RUSTC_WRAPPER: "sccache"
steps:
- uses: actions/checkout@v6
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: Swatinem/rust-cache@v2
- uses: mozilla-actions/sccache-action@v0.0.9
- run: sccache --show-stats || true
- name: Publish to crates.io
env:
CRATES_TOKEN: ${{ secrets.CRATES_TOKEN }}
run: cargo publish --token $CRATES_TOKEN