repo-standards
repo-standards measures pull-request review size without executing repository code. Its
repository rules are available for review but remain disabled until individually approved
and explicitly activated by a consumer.
Where rules belong
- Exact tracked-tree facts—filenames, placement, topology, migrations, pull-request size, ownership, delivery/GitHub state, and repository-wide API/document sets—belong here.
- Source and configuration semantics for Python, TypeScript, SQL, Terraform/HCL, Markdown,
YAML, JSON, and shell belong in
sarj-ai/code-standards. - If a path alone is sufficient to produce the finding, use Repo Standards. If source content is necessary, use Code Standards.
After a rule is approved, activate its stable ID in .repo-standards/repository.toml:
enabled_rules = ["repository/artifacts/bespoke-iac-verifiers"]
The locked Repo Standards release supplies the current reviewed implementation. Manifests never
select historical rule versions; --enable-rule <rule-id>@<version> remains available only for
legacy manifests and calibration runs.
Run it
Use the current release without installing it:
uvx --from repo-standards repo-standards pull-request size . --base origin/main
For a persistent user installation:
uv tool install repo-standards
repo-standards pull-request size . --base origin/main
Upgrade with uv tool upgrade repo-standards. Automation should pin the package version or
the GitHub Action's full commit SHA.
GitHub Action
The Action measures size only. It enables no repository lint rules and needs no inputs on a
pull_request event.
name: Pull-request size
on:
pull_request:
permissions:
contents: read
jobs:
size:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
fetch-depth: 0
persist-credentials: false
- uses: sarj-ai/repo-standards@ece675a4ba04bc4e3ffa1ceb26ebbedabe13e78a # v5.8.0
The Action emits counted, excluded, and total line counts plus canonical JSON. Tests are recognized across Python, JavaScript/TypeScript, Go, JVM, Android, Xcode/Swift, .NET, Ruby, and Bats conventions. Mark generated or machine-owned artifacts in the trusted base revision:
path/to/generated/** pr-size-excluded
Thresholds, labels, comments, and approval requirements remain consumer policy. Use
pull_request, never pull_request_target; this metric is not a security gate.
Safety model
- Repository contents come from one exact Git tree.
- Workflow YAML and API descriptions are parsed as inert data.
- Missing required evidence produces an inconclusive result rather than a false pass.
- The linter has no autofix or repository mutation mode.
Development
uv sync --locked
uv run pytest
uv run ruff check .
uv run basedpyright
uvx --no-config --isolated --python 3.14 \
--from sarj-standards-bootstrap==2.0.0 \
code-standards check --trust-repository-code
Build the same wheel and source distribution used by publishing:
uv build --no-sources
Releases are reconcilable. The protected workflow independently repairs a missing PyPI publication or GitHub Release from the same verified source revision.
Release files for repo-standards 5.8.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| repo_standards-5.8.0.tar.gz | 96.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| repo_standards-5.8.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 207.8 kB
Release files / repo_standards-5.8.0.tar.gz
| Download URL | repo_standards-5.8.0.tar.gz |
|---|---|
| Size | 96.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
334294cb8efa6801e0548bba91eaeaaf7b05b05232be4331f44dd10090e8c892
|
|
BLAKE2b-256 checksum How to use checksums |
d280ad9858f548500db6a2e43f0431cc893bc126e7510affe1eb72e90bdf47fa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Aug 26, 2026.
Transparency logRelease files / repo_standards-5.8.0-py3-none-any.whl
| Download URL | repo_standards-5.8.0-py3-none-any.whl |
|---|---|
| Size | 111.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ba6decf4ac82632c1e86c8a8d8fd0d39047decde96008b832f1a785e6b0c4dad
|
|
BLAKE2b-256 checksum How to use checksums |
fb169441ee4af05129a7f077a6b77548a553bb6a63f7f0bc420b9eb1046c7559
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Aug 26, 2026.
Transparency log