Bump the minor-changes group with 3 updates #137
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
env: | |
msrv: "1.65" | |
nightly: nightly-2023-09-09 | |
jobs: | |
# Checks minimum supported Rust version. | |
build-msrv: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install packages | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y --no-install-suggests --no-install-recommends libsodium-dev | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@master | |
with: | |
toolchain: ${{ env.msrv }} | |
- name: Cache cargo build | |
uses: actions/cache@v3 | |
with: | |
path: target | |
key: ${{ runner.os }}-msrv-cargo-${{ hashFiles('**/Cargo.lock') }} | |
restore-keys: ${{ runner.os }}-msrv-cargo | |
- name: Build with ES256, ES256K & RSA | |
run: cargo build -p jwt-compact --lib --features exonum-crypto,p256,es256k,rsa | |
- name: Build with ed25519-compact | |
run: cargo build -p jwt-compact --no-default-features --features std,ed25519-compact --lib | |
- name: Build with dalek crypto | |
run: cargo build -p jwt-compact --no-default-features --features std,ed25519-dalek --lib | |
- name: Build with k256 crypto | |
run: cargo build -p jwt-compact --no-default-features --features k256 --lib | |
build: | |
uses: ./.github/workflows/build-reusable.yml | |
with: | |
nightly_rust_version: nightly-2023-09-09 | |
document: | |
needs: | |
- build | |
- build-msrv | |
if: github.event_name == 'push' | |
permissions: | |
contents: write | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
persist-credentials: false | |
- name: Install packages | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y --no-install-suggests --no-install-recommends libsodium-dev | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@master | |
with: | |
toolchain: ${{ env.nightly }} | |
- name: Cache cargo build | |
uses: actions/cache@v3 | |
with: | |
path: target | |
key: ${{ runner.os }}-document-cargo-${{ hashFiles('**/Cargo.lock') }} | |
restore-keys: ${{ runner.os }}-document-cargo | |
- name: Build docs | |
run: | | |
cargo clean --doc && \ | |
cargo rustdoc -p jwt-compact --features exonum-crypto,p256,es256k,rsa -- \ | |
--cfg docsrs -Z unstable-options \ | |
--extern-html-root-url base64ct=https://docs.rs/base64ct/1.5.2 \ | |
--extern-html-root-url exonum-crypto=https://docs.rs/exonum-crypto/1.0.0 \ | |
--extern-html-root-url anyhow=https://docs.rs/anyhow/~1.0 \ | |
--extern-html-root-url secp256k1=https://docs.rs/secp256k1/~0.27 \ | |
--extern-html-root-url serde_json=https://docs.rs/serde_json/~1 \ | |
--extern-html-root-url serde_cbor=https://docs.rs/serde_cbor/~0.11 \ | |
--extern-html-root-url rsa=https://docs.rs/rsa/~0.9 | |
- name: Deploy | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
branch: gh-pages | |
folder: target/doc | |
single-commit: true |