utils/repo_contract/templates/agent-ready.yml
Krzysztof kuhy Rudnicki a0fb279b1b agent_ready: AgentReady v2.0 checker + repo_contract web-site gate
New agent_ready/ package (dist and live-url modes, 100% branch coverage)
checks robots, sitemap, llms.txt, ai-catalog, 404, no-JS text, markdown
mirrors and JSON-LD. repo_contract gains web-repo detection and installs the
agent-ready pre-commit hook, CI workflow and check_agent_ready.sh shim;
scripts/check_agent_ready.sh is the shared entry point.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NBScELfMUiieK9ManFbS3Y
2026-10-22 21:18:49 +02:00

51 lines
1.7 KiB
YAML

name: agent-ready
# Every website kuhy owns passes the AgentReady checker. The local pre-commit
# hook can be skipped (a fresh clone has no hooks), so this rebuilds the site
# from a clean checkout and checks the output on every push. Settings live in
# repo-contract.toml [agent_ready]; see ~/src/utils/repo_contract/web.py.
on:
push:
branches: [main]
pull_request:
workflow_dispatch:
jobs:
agent-ready:
name: AgentReady
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
# The gate (repo_contract) and the checker (agent_ready) both live in
# the shared utils repo, so every site is judged by the same checker.
- name: Check out the shared gate
uses: actions/checkout@v4
with:
repository: kuhyx/utils
path: .utils
# The gate and checker are stdlib-only (tomllib needs 3.11+).
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.x"
# Node comes from .nvmrc (the dependency-freshness pin). Without one the
# runner's preinstalled Node builds the site; a channel name like lts/*
# here would turn the dependency-freshness gate red in every site repo.
- name: Set up Node (pinned by .nvmrc)
if: hashFiles('.nvmrc') != ''
uses: actions/setup-node@v4
with:
node-version-file: .nvmrc
# pnpm switches itself to the `packageManager` version in package.json.
- name: Install pnpm
if: hashFiles('pnpm-lock.yaml') != ''
run: npm install --global pnpm
- name: Build and check the site
run: bash .utils/scripts/check_agent_ready.sh --strict --install