This recipe bootstraps a typical Node CLI repo:
- a small CLI published as npm package (or internal tool)
- build via TypeScript (optional) and lint/test scripts
It gives you:
AGENTS.md/RUNBOOK.mdwith marker-only safe updates.agentsgen.jsonwith explicit commands- PR Guard workflow snippet
package.jsonsrc/(TypeScript) orbin//index.jstsconfig.json(if TS)dist/(if build output)
If built-in presets are enough, start with agentsgen presets and agentsgen init . --preset cli-node before copying this recipe.
- Copy
.agentsgen.jsonfrom this folder to your repo root. - Run:
agentsgen init . --defaults
agentsgen update . --dry-run --print-diff
agentsgen pack . --check --format jsonCreate .github/workflows/agentsgen-guard.yml:
name: agentsgen guard + pack check
on:
pull_request:
push:
branches: [ main ]
permissions:
contents: read
pull-requests: write
jobs:
agentsgen:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: markoblogo/AGENTS.md_generator/.github/actions/agentsgen-guard@main
with:
comment: "true"
files: "AGENTS.md,RUNBOOK.md"
pack_check: "true"
pack_format: "json"- Replace the default
commandsin.agentsgen.jsonto match your CLI setup (Typer/Click for Python, ornode ./binfor Node). - If your CLI code is not at repo root (e.g.
packages/cli), point init/update to that folder or set a workspace path in.agentsgen.json.