Runbook: Update Pave Documentation
When to Use
Use this runbook when updating pave’s own documentation. This applies when:
- Modifying source code in
src/that changes behavior - Adding or changing CLI commands
- Modifying configuration options in
.pave.toml - Fixing bugs that affect documented behavior
- Adding new features that need documentation
Preconditions
- Rust toolchain installed (via rustup)
- Repository cloned locally
- Understanding of the PAVED framework
- Familiarity with the change that requires documentation updates
Steps
1. Check which docs are impacted
After making code changes, run the changed command to see which documentation files may need updates:
cargo run -- changed
This analyzes source mappings to identify documentation that references modified code.
2. Review and update affected documentation
For each impacted document:
- Read the existing content
- Update sections that reference changed behavior
- Add new sections if the change introduces new functionality
- Remove outdated information
Common documents to check:
docs/components/- Component documentation for modified subsystemsdocs/runbooks/- Runbooks referencing changed commandssite/docs/commands.md- CLI command reference
3. Validate documentation structure
Run the check command to ensure all documentation follows PAVED rules:
cargo run -- check
Fix any validation errors before proceeding.
4. Run verification commands
Execute verification blocks embedded in documentation to ensure examples still work:
cargo run -- verify
Fix any failing verifications by updating the documentation or fixing the underlying code.
5. Update the index if needed
If you added new documents, regenerate the index:
cargo run -- index --update
6. Run the full test suite
Ensure all tests pass:
cargo test
Rollback
If documentation changes are incorrect or break CI:
git checkout -- docs/
Or revert specific files:
git checkout -- docs/path/to/file.md
Verification
Confirm documentation is correct:
./target/release/pave check
cargo test
Escalation
For a small project like pave, escalation is typically not needed. If issues arise:
- Review the PAVED manifesto for documentation guidelines
- Check existing documents in
docs/for patterns - Open an issue on the pave repository
Examples
Adding documentation for a new command
After adding a stats command to the codebase:
- Check impacted docs:
cargo run -- changed - Create component documentation:
cargo run -- new component stats -
Fill out
docs/components/stats.mdwith purpose, interface, and examples -
Update
site/docs/commands.mdwith CLI usage - Validate:
cargo run -- check
Updating documentation after a bug fix
After fixing a bug in the check command:
- Review
docs/components/validation-engine.mdfor accuracy - Update any examples that showed the buggy behavior
- Run
cargo run -- verifyto ensure examples work - Run
cargo run -- checkto validate structure
Documenting a configuration change
After adding a new config option:
- Update
docs/components/configuration.mdwith the new option - Add the option to any relevant examples
- Update
.pave.tomlif it serves as a reference - Validate with
cargo run -- check