serde_fields 0.1.0

Macro making rendered serde field-names available as `&'static str`
Documentation
name: Publish to crates.io

on:
  push:
    tags:
      - "v*"

jobs:
  publish:
    name: Publish crate version
    runs-on: ubuntu-latest
    permissions:
      contents: read

    steps:
      - name: Checkout
        uses: actions/checkout@v4

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

      - name: Run tests
        run: |
          cargo test --all --release

      - name: Publish to crates.io
        run: |
          TAG_VERSION="${GITHUB_REF#refs/tags/v}"
          FILE_VERSION=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[0].version')

          if [ "$TAG_VERSION" != "$FILE_VERSION" ]; then
          echo "Tag version $TAG_VERSION does not match Cargo.toml version $FILE_VERSION" >&2
          exit 1
          fi

          cargo publish --token ${{ secrets.CARGO_REGISTRY_TOKEN }}