Skip to main content

codelaw

A linter and formatter whose rules are Markdown files — for JavaScript, TypeScript, Python, JSON, YAML, TOML, Markdown, CSS and HTML, alone or mixed.

One engine, two registries, identical output. The same native binary ships as codelaw on npm and on PyPI; neither needs the other.

Install

your repo engine rules for its languages
Node npm i -D codelaw npx codelaw init adds the @codelaw/rules-* packs
Python uv add --dev codelaw or pip install codelaw codelaw init adds the codelaw-rules-* packs

codelaw installed alone lints nothing until a rule pack is installed — it says so (codelaw/no-rules).

Agent files — skills, steering, instructions, hooks and MCP registration for Claude Code, Cowork, Copilot, Codex and Kiro — are a package of their own, at codelaw's exact version: npm i -D @codelaw/skills or pip install codelaw-skills. codelaw init --agents installs it; codelaw sync-agents needs it.

Rule packs — each registry carries the packs its users install:

registry named packs
npm @codelaw/rules-<name> js · ts · react · node · stencil · html · css · scss · css-modules · data · tanstack-query · redux-toolkit · security-js · security-ts · security-html · spell · deps
PyPI codelaw-rules-<name> js · react · html · css · scss · python · data · security-js · security-html · security-python · spell · deps

Use

codelaw check            # lint the project
codelaw fix              # apply the safe fixes
codelaw check --format json

Programmatic API — runs the bundled binary and returns its JSON report:

import { check, fix, format, rulesFor } from "codelaw";
const report = check(["src"]);
const rules = rulesFor("src/app.ts");
import codelaw
report = codelaw.check(["src"])
rules = codelaw.rules_for("app/main.py")
npm Python what it returns
check(paths, options) check(paths, …) codelaw check --format json
fix(paths, options) fix(paths, …) codelaw fix --format json; unsafe, dryRun / dry_run
format(paths, options) format(paths, …) codelaw format --format json; check writes nothing
rulesFor(path) rules_for(path) the rules that apply to one file, as codelaw rules --for lists them
binaryPath(), platformKey() binary_path() the bundled binary, and the platform key it was chosen by

Platforms

macOS arm64 and x64 · Linux x64 and arm64, glibc and musl · Windows x64 and arm64. Any other platform fails with an error naming these — codelaw never compiles from source at install time.

Licence

MIT — https://github.com/arpitarya/codelaw

Metadata

Release files for codelaw 0.4.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for codelaw 0.4.3
File Actions
codelaw-0.4.3-py3-none-win_arm64.whl Python 3 none Windows ARM64 Details for codelaw-0.4.3-py3-none-win_arm64.whl
codelaw-0.4.3-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details for codelaw-0.4.3-py3-none-win_amd64.whl
codelaw-0.4.3-py3-none-musllinux_1_2_x86_64.whl Python 3 none Linux musl 1.2+ x86-64 Details for codelaw-0.4.3-py3-none-musllinux_1_2_x86_64.whl
codelaw-0.4.3-py3-none-musllinux_1_2_aarch64.whl Python 3 none Linux musl 1.2+ ARM64 Details for codelaw-0.4.3-py3-none-musllinux_1_2_aarch64.whl
codelaw-0.4.3-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl Python 3 none Linux glibc 2.17+ x86-64 Details for codelaw-0.4.3-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
codelaw-0.4.3-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl Python 3 none Linux glibc 2.17+ ARM64 Details for codelaw-0.4.3-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
codelaw-0.4.3-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details for codelaw-0.4.3-py3-none-macosx_11_0_arm64.whl
codelaw-0.4.3-py3-none-macosx_10_12_x86_64.whl Python 3 none macOS 10.12+ x86-64 Details for codelaw-0.4.3-py3-none-macosx_10_12_x86_64.whl

Total release size: 104.2 MB

Release files / codelaw-0.4.3-py3-none-win_arm64.whl

Download URL codelaw-0.4.3-py3-none-win_arm64.whl
Size 12.8 MB
Tags Python 3 Windows ARM64
SHA-256 checksum
How to use checksums
598e852455b5b7e94f588de108e8c5c1ef50b53b2baa840623fd3cac4dbc23b0
BLAKE2b-256 checksum
How to use checksums
2d753b476841f1cd01ae748ad884c198b7895694b0c998ab2d40c6ebd9fcc09a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / codelaw-0.4.3-py3-none-win_amd64.whl

Download URL codelaw-0.4.3-py3-none-win_amd64.whl
Size 13.9 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
24b311e3f97e368bb9a43dabcb1ab1039acaa2753400da79df3c417c8015a27e
BLAKE2b-256 checksum
How to use checksums
31bf48053dbf56beeba78e1062bcb23982e1ce6646b2c186159c518b245f9bf7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / codelaw-0.4.3-py3-none-musllinux_1_2_x86_64.whl

Download URL codelaw-0.4.3-py3-none-musllinux_1_2_x86_64.whl
Size 13.4 MB
Tags Linux musl 1.2+ x86-64 Python 3
SHA-256 checksum
How to use checksums
2471da88ad42f922a86edfb2d9fc6f0db01993316f115a62d64e3ef9816bc7d2
BLAKE2b-256 checksum
How to use checksums
5af9fea7b8662823d2e52b284f96305bee137d9ad652904af4fe8f7bdec21f26
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / codelaw-0.4.3-py3-none-musllinux_1_2_aarch64.whl

Download URL codelaw-0.4.3-py3-none-musllinux_1_2_aarch64.whl
Size 12.5 MB
Tags Linux musl 1.2+ ARM64 Python 3
SHA-256 checksum
How to use checksums
62527e61a1f801b681b3fc54f1e64fb9026c6d6e28b3cf489d999ea59a93b1c9
BLAKE2b-256 checksum
How to use checksums
afe50948b09129b98214817b7b2b6b7a12aab2b2b1f72ce0596a52856041ace7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / codelaw-0.4.3-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL codelaw-0.4.3-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 13.4 MB
Tags Linux glibc 2.17+ x86-64 Python 3
SHA-256 checksum
How to use checksums
9aeeb9b60b9c3ba7fa5e0072d1afc4c3fc7e8353b65f3b76edf86e912ec38840
BLAKE2b-256 checksum
How to use checksums
410bc43c7f1a0b9fc342601b73febea070db318d33ef585b2a2654e6d9b5e2a2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / codelaw-0.4.3-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL codelaw-0.4.3-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 12.5 MB
Tags Linux glibc 2.17+ ARM64 Python 3
SHA-256 checksum
How to use checksums
d483bfe08b25b6a8532afd1ef5a3ffbfde8907e5b51c343cb45ec82f6731dfe8
BLAKE2b-256 checksum
How to use checksums
afdce180cc9d10cfcc88f0f70eb3c0ac0bb501843a0d5befd19ba4dcd7e08270
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / codelaw-0.4.3-py3-none-macosx_11_0_arm64.whl

Download URL codelaw-0.4.3-py3-none-macosx_11_0_arm64.whl
Size 12.5 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
c9db0931baf23c50b2b7a898c05ce8e3eaacc7f22c68c560a5f5f2ae64591ba1
BLAKE2b-256 checksum
How to use checksums
420632e730741f9144adfeb5268b5a59cadfd9b49265a20abd057226777901df
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Release files / codelaw-0.4.3-py3-none-macosx_10_12_x86_64.whl

Download URL codelaw-0.4.3-py3-none-macosx_10_12_x86_64.whl
Size 13.2 MB
Tags Python 3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
761cb5cfef2b5633e6ea2035823fe941d36ba3750211f8588ee7f59250848ef9
BLAKE2b-256 checksum
How to use checksums
ef4ec1453ef47639baee48ae9cbd559459a3d57d0a1bdd22d6cf91b2d2e218ac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

Security for codelaw 0.4.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 8 files in this release have been uploaded with provenance metadata.

Select from 8 files

Attestation for codelaw-0.4.3-py3-none-win_arm64.whl

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 30, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page