Skip to content

Migration to v1.4.0

From v1.3.0 to v1.4.0.

Adds a rust-llm-tidy CI job: it tidies the files a PR changes, then pushes the fixes back to the branch. New projects include it by default.

1. Add .rust-llm-tidy.yml

Create at the repository root:

# rust-llm-tidy config.
#
# All checks the tool currently supports are listed. New tool release? Add
# its new checks here; unlisted checks stay off.
#
# Upstream references:
# - Tool's own config: https://github.com/Sewer56/rust-llm-tidy/blob/main/.rust-llm-tidy.yml
# - All options: https://github.com/Sewer56/rust-llm-tidy/blob/main/.rust-llm-tidy.example.yml

include:
  # paths omitted: rules apply to all files.
  - rules:
      # Level 1: Markdown/doc-comment formatting.
      - tables
      - fences
      - links

      # Level 2: Rust source cleanup.
      - reorder
      - vis

      # Level 3: documentation and test-name checks, pinned individually.
      - DOC001
      - DOC002
      - DOC003
      - DOC004
      - DOC005
      - DOC006
      - TEST001

2. Add .github/workflows/tidy.yml

name: Tidy

on:
  pull_request:
    paths:
      - "src/**"
      - "**/*.md"
      - ".rust-llm-tidy.yml"

concurrency:
  group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
  cancel-in-progress: true

jobs:
  tidy:
    runs-on: ubuntu-latest
    permissions:
      contents: write
      pull-requests: write
    steps:
      - uses: actions/checkout@v7
        with:
          ref: ${{ github.head_ref }}
          submodules: recursive

      # Runs my linter.
      - name: Run rust-llm-tidy
        uses: Sewer56/rust-llm-tidy-action@v1
        with:
          mode: apply
          changed-files: "true"
          release-tag: "0.4.1"

Fork PRs

Apply mode cannot push to forks. Run rust-llm-tidy locally, push. Never switch this workflow to pull_request_target with a PAT.

3. Update the template version marker

- reloaded-templates-rust:1.3.0
+ reloaded-templates-rust:1.4.0

Notes

  • Only Rust and Markdown files are processed. Vendored assets need no excludes.
  • exclude_files patterns matching zero files are config errors. After editing, run rust-llm-tidy --validate.