Skip to content

Publish to crates.io #3

Publish to crates.io

Publish to crates.io #3

Workflow file for this run

name: Publish to crates.io
on:
push:
tags:
- 'v*.*.*'
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
jobs:
publish:
name: Publish lighter-rs
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
- name: Run tests
run: cargo test --all-features
- name: Run clippy
run: cargo clippy --all-targets -- -A clippy::vec_init_then_push
- name: Build release
run: cargo build --release
- name: Publish to crates.io
run: cargo publish
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}