Repository navigation
Releases
v0.5.1
Patch Changes
- 7b331b3: AutoRatchet reads limits from eslint-plugin-sonarjs rules in
.oxlintrc.json:sonarjs/cognitive-complexityfor cognitive andsonarjs/cyclomatic-complexityfor cyclomatic. Override comments acceptsonarjs/cyclomatic-complexity.
v0.5.0
Minor Changes
- 10559b7: AutoRatchet takes complexity limits from your linter config:
.oxlintrc.json,biome.json, Ruff,clippy.tomland golangci-lint. Each language gets its own limit, and the report names the file that set it. The action'sthresholdandcognitive-thresholdinputs now default to your config.
v0.4.6
Patch Changes
- 7f2e9e8:
autoratchet --version(or-V) prints the version.
v0.4.5: Python and Go support
AutoRatchet stops functions from getting more complex, without asking you to fix the complex code you already have. It gives the same verdict on your machine, in your AI coding agent's hooks and on every pull request.
What's new since 0.3
- Python: cyclomatic scores match radon, cognitive scores match complexipy. Reads
# noqa: C901and# complexipy: ignore. - Go: scores match gocyclo and gocognit, recursion across the package included. Reads
//nolint:gocyclo,gocognitand//gocognit:ignore. - Rust, Python and Go need only the
autoratchetbinary. No Node.js. - The action posts its report, marks regressed functions in the diff and keeps one PR comment current on every run.
- In
labelmode, adding the approval label reruns the check and approves the override.
Use it
# .github/workflows/autoratchet.yml
name: AutoRatchet
on:
pull_request:
types: [opened, synchronize, reopened, labeled, unlabeled]
pull_request_review:
types: [submitted, dismissed]
permissions:
contents: read
pull-requests: write
jobs:
ratchet:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: jagreehal/autoratchet@v0.4.5
with:
path: src
override-approval: reviewOn your machine: npx autoratchet check --base main, or download the binary for your platform below.
Patch Changes
- 91bd1cb: The GitHub Action reads the pull request's current labels in
labelmode, so adding the approval label and rerunning the check approves the override. The README's workflow runs the check when someone adds or removes a label.
The Claude Code hook lists an override comment once when it covers both metrics.
v0.4.4: Python and Go support
AutoRatchet stops functions from getting more complex, without asking you to fix the complex code you already have. It gives the same verdict on your machine, in your AI coding agent's hooks and on every pull request.
What's new since 0.3
- Python: cyclomatic scores match radon, cognitive scores match complexipy. Reads
# noqa: C901and# complexipy: ignore. - Go: scores match gocyclo and gocognit, recursion across the package included. Reads
//nolint:gocyclo,gocognitand//gocognit:ignore. - Rust, Python and Go need only the
autoratchetbinary. No Node.js.
Use it
- uses: actions/checkout@v7
with:
fetch-depth: 0
- uses: jagreehal/autoratchet@v0.4.2
Locally: npx autoratchet check --base main, or download the binary for your platform below.v0.4.3
v0.4.2: Python and Go support
AutoRatchet stops functions from getting more complex, without asking you to fix the complex code you already have. It gives the same verdict on your machine, in your AI coding agent's hooks and on every pull request.
What's new since 0.3
- Python: cyclomatic scores match radon, cognitive scores match complexipy. Reads
# noqa: C901and# complexipy: ignore. - Go: scores match gocyclo and gocognit, recursion across the package included. Reads
//nolint:gocyclo,gocognitand//gocognit:ignore. - Rust, Python and Go need only the
autoratchetbinary. No Node.js.
Use it
- uses: actions/checkout@v7
with:
fetch-depth: 0
- uses: jagreehal/autoratchet@v0.4.2
Locally: npx autoratchet check --base main, or download the binary for your platform below.v0.4.1
Patch Changes
- 2948094: The GitHub Action has a short description that fits the GitHub Marketplace listing. It and the package description name the five languages AutoRatchet measures and the places it runs: on your machine, in AI coding agent hooks and in CI.
v0.4.0
Minor Changes
- cd6423b: AutoRatchet measures Python and Go. Python scores follow radon for cyclomatic complexity and complexipy for cognitive complexity; Go scores follow gocyclo and gocognit. Each language reads the override comments its developers write today (
# noqa: C901,# complexipy: ignore,//nolint:gocyclo,gocognit,//gocognit:ignore), and both run from the AutoRatchet binary alone.
v0.3.1
Patch Changes
- 1547238: The GitHub Action downloads the AutoRatchet release binary, checked against
SHA256SUMS, and Oxlint only when the paths include JavaScript or TypeScript. It runs without Node.js.