random-image-server 0.2.1

A simple image server that serves random images from a preconfigured list of paths and URLs.
Documentation
name: Publish to Crates.io

on:
  release:
    types: [released, prereleased ]
  workflow_dispatch:

env:
  CARGO_TERM_COLOR: always
  RUST_BACKTRACE: "full"

concurrency:
  group: Publish-${{ github.ref }}
  cancel-in-progress: true

jobs:
  crates-io-publish:
    name: Publish to crates.io
    runs-on: ubuntu-latest
    env:
      CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
      CRATE: random-image-server
    steps:
      - name: Checkout
        uses: actions/checkout@v4

      - name: Install toolchain
        uses: dtolnay/rust-toolchain@stable

      - name: Setup cache
        uses: Swatinem/rust-cache@v2
        with:
          shared-key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

      - name: Publish to crates.io
        run: cargo publish --token=$CARGO_REGISTRY_TOKEN