diff --git a/.agents/skills/task-closeout/SKILLS.md b/.agents/skills/task-closeout/SKILL.md similarity index 95% rename from .agents/skills/task-closeout/SKILLS.md rename to .agents/skills/task-closeout/SKILL.md index 7d544a8..e23ae2b 100644 --- a/.agents/skills/task-closeout/SKILLS.md +++ b/.agents/skills/task-closeout/SKILL.md @@ -17,4 +17,4 @@ When this skill is used: 7. Stop. Do not perform release actions. -Do not merge into main. \ No newline at end of file +Do not merge into main. diff --git a/README.md b/README.md index 71282bf..44a6bbb 100644 --- a/README.md +++ b/README.md @@ -92,6 +92,7 @@ When starting on a new machine: 2. Authenticate Codex locally. 3. Checkout the correct branch, typically `develop` or the assigned task branch. 4. Read `AGENTS.md`, `docs/WORKFLOW.md`, `docs/MACHINE_SETUP.md`, and `docs/TASK_TEMPLATE.md`. +5. Run `make doctor` to validate the local repository bootstrap before starting a task. ## Codex Task Style @@ -108,7 +109,7 @@ Codex tasks in this repository should follow this order: ## Local Checks -Run `make doctor` to perform the repository's local bootstrap and environment checks. +Run `make doctor` as part of machine/bootstrap validation to confirm the repository foundation is present and aligned. ## Current Status diff --git a/docs/MACHINE_SETUP.md b/docs/MACHINE_SETUP.md index 5b786a3..a596ffe 100644 --- a/docs/MACHINE_SETUP.md +++ b/docs/MACHINE_SETUP.md @@ -37,7 +37,8 @@ Use this sequence on a new machine: - `docs/WORKFLOW.md` - `docs/MACHINE_SETUP.md` - `docs/TASK_TEMPLATE.md` -5. Create a task branch from `develop`. +5. Run `make doctor`. +6. Create a task branch from `develop`. ## Validation Checklist @@ -48,12 +49,15 @@ A machine is ready for repository work when: - `AGENTS.md` is present - `.codex/config.toml` is present - `.codex/agents/` is present -- docs are present +- `.agents/skills/` is present +- `docs/WORKFLOW.md` is present +- `docs/MACHINE_SETUP.md` is present +- `docs/TASK_TEMPLATE.md` is present - `make doctor` works ## Local Checks -Run `make doctor` to verify the repository bootstrap and local working assumptions. +Run `make doctor` during bootstrap to verify the repository bootstrap and local working assumptions. ## Troubleshooting diff --git a/docs/WORKFLOW.md b/docs/WORKFLOW.md index c1dd51b..b6382db 100644 --- a/docs/WORKFLOW.md +++ b/docs/WORKFLOW.md @@ -80,6 +80,7 @@ Example feature branch flow: ```bash git checkout develop git pull +# if git pull fails, continue using local branch state and say so explicitly git checkout -b feature/example-task # make focused changes git commit -m "docs: describe example task flow" diff --git a/scripts/doctor.sh b/scripts/doctor.sh index 4718ba4..5523290 100644 --- a/scripts/doctor.sh +++ b/scripts/doctor.sh @@ -6,13 +6,17 @@ echo "== Repo doctor ==" test -f AGENTS.md && echo "AGENTS.md: OK" || { echo "AGENTS.md: MISSING"; exit 1; } test -f .codex/config.toml && echo ".codex/config.toml: OK" || { echo ".codex/config.toml: MISSING"; exit 1; } test -d .codex/agents && echo ".codex/agents: OK" || { echo ".codex/agents: MISSING"; exit 1; } -test -d docs && echo "docs/: OK" || { echo "docs/: MISSING"; exit 1; } +test -d .agents/skills && echo ".agents/skills: OK" || { echo ".agents/skills: MISSING"; exit 1; } +test -f .agents/skills/task-closeout/SKILL.md && echo ".agents/skills/task-closeout/SKILL.md: OK" || { echo ".agents/skills/task-closeout/SKILL.md: MISSING"; exit 1; } +test -f docs/WORKFLOW.md && echo "docs/WORKFLOW.md: OK" || { echo "docs/WORKFLOW.md: MISSING"; exit 1; } +test -f docs/MACHINE_SETUP.md && echo "docs/MACHINE_SETUP.md: OK" || { echo "docs/MACHINE_SETUP.md: MISSING"; exit 1; } +test -f docs/TASK_TEMPLATE.md && echo "docs/TASK_TEMPLATE.md: OK" || { echo "docs/TASK_TEMPLATE.md: MISSING"; exit 1; } branch="$(git rev-parse --abbrev-ref HEAD)" echo "Current branch: ${branch}" if [[ "${branch}" == "main" || "${branch}" == "develop" ]]; then - echo "Warning: create a task branch before making changes." + echo "Warning: do not make changes on ${branch}; create a task branch from develop first." fi -echo "Doctor completed." \ No newline at end of file +echo "Doctor completed."