Skip to main content

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, opt in per run with --enable-rule <rule-id>@<version>. Approval alone never enables a rule, and the option may be repeated for multiple approved rules.

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@b8b41d488fd0f116081e16bbae2da61d632316b1 # v5.3.1

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.3.1

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

Source distribution (sdist)

Source distribution for repo-standards 5.3.1
File Size Uploaded
repo_standards-5.3.1.tar.gz 85.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for repo-standards 5.3.1
File Interpreter ABI Platform
repo_standards-5.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 184.5 kB

Release files / repo_standards-5.3.1.tar.gz

Download URL repo_standards-5.3.1.tar.gz
Size 85.4 kB
Tags Source
SHA-256 checksum
How to use checksums
c3929b6cc95bf9dac474b255e26af1b4d5da6e341857fb550e0af45b4ef1722b
BLAKE2b-256 checksum
How to use checksums
89f64113aa6a806ffcc3248dc330f1acb3e0b4d9999289bd10522dc064b05700
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 25, 2026.

Transparency log

Release files / repo_standards-5.3.1-py3-none-any.whl

Download URL repo_standards-5.3.1-py3-none-any.whl
Size 99.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
74329409f462bdf8081390fd8dc25f7b6b5526c4f9a84a9f5aab52054d4e7216
BLAKE2b-256 checksum
How to use checksums
454195c0bb241a5ad8cbf7229993f39afb297d53e77d4dd80170fc80b414a1db
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 25, 2026.

Transparency log

Release history Release notifications | RSS feed

6.1.2

2 release files

6.1.1

2 release files

6.1.0

2 release files

6.0.1

2 release files

6.0.0

2 release files

5.17.0

2 release files

5.16.8

2 release files

5.16.7

2 release files

5.16.6

2 release files

5.16.5

2 release files

5.16.4

2 release files

5.16.3

2 release files

5.16.2

2 release files

5.16.1

2 release files

5.16.0

2 release files

5.15.0

2 release files

5.14.1

2 release files

5.14.0

2 release files

5.13.2

2 release files

5.13.1

2 release files

5.13.0

2 release files

5.12.0

2 release files

5.9.0

2 release files

5.8.0

2 release files

5.7.0

2 release files

5.6.1

2 release files

5.6.0

2 release files

5.5.3

2 release files

5.5.2

2 release files

5.5.1

2 release files

5.5.0

2 release files

5.4.1

2 release files

5.4.0

2 release files

This release

5.3.1 This release

2 release files

5.3.0

2 release files

5.2.1

2 release files

5.2.0

2 release files

5.1.0

2 release files

5.0.1

2 release files

5.0.0

2 release files

4.0.2

2 release files

4.0.1

2 release files

4.0.0

2 release files

3.0.2

2 release files

3.0.1

2 release files

3.0.0

2 release files

2.0.0

2 release files

1.0.0

2 release files

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