|
| 1 | +# AGENTS.md |
| 2 | + |
| 3 | +## Project Overview |
| 4 | + |
| 5 | +`openwisp-docs` contains the OpenWISP documentation published on openwisp.io. |
| 6 | + |
| 7 | +Core content lives in this repository root: |
| 8 | + |
| 9 | +- `modules/`, `user/`, `developer/`, `general/`, `tutorials/`, `releases/`, and top-level `.rst` files contain documentation content. |
| 10 | +- `_static/`, `_templates/`, `_styles/`, `assets/`, `images/`, and `partials/` contain presentation assets and shared snippets. |
| 11 | +- `conf.py`, `config.yml`, `build.py`, `Makefile`, and helper scripts support documentation builds and releases. |
| 12 | + |
| 13 | +## Source of Truth |
| 14 | + |
| 15 | +- Use `README.rst` and `developer/contributing.rst` for setup, style, and contribution guidance. |
| 16 | +- Use `.github/workflows/ci.yml`, `pyproject.toml`, and `requirements.txt` for CI-tested docs build, QA, spelling, and link checks. |
| 17 | +- Use GitHub issue/PR templates when asked to open issues or PRs. |
| 18 | + |
| 19 | +If instructions conflict, repository config and CI workflows win first, docs next, and this file is supplemental. |
| 20 | + |
| 21 | +## Development Notes |
| 22 | + |
| 23 | +- Keep changes focused. Avoid unrelated rewrites, formatting churn, and broad style changes. |
| 24 | +- Preserve headings, anchors, cross-references, versioned links, include directives, image paths, and public URLs unless explicitly required. |
| 25 | +- Be careful with release notes, version switcher behavior, generated files, spell-check word lists, and module documentation copied from upstream repos. |
| 26 | +- Avoid unnecessary blank lines inside directive blocks, literal blocks, and helper functions. |
| 27 | +- Update navigation and index files when adding, moving, or removing pages. |
| 28 | + |
| 29 | +## Testing and QA |
| 30 | + |
| 31 | +- Add or update docs examples and references for behavior changes. |
| 32 | +- For documentation bug fixes, reproduce the broken build, link, warning, or rendered output when feasible before changing it. |
| 33 | +- Use targeted docs builds while iterating, then run the documented full QA/build command before considering the change complete. |
| 34 | +- Run `./run-qa-checks` when present. Treat failures as blocking unless confirmed unrelated and reported. |
| 35 | + |
| 36 | +## Security Notes |
| 37 | + |
| 38 | +- Watch for leaked secrets, unsafe links, stale security guidance, broken HTTPS links, and instructions that encourage insecure deployments. |
| 39 | +- Preserve safe handling around downloads, install commands, credentials, tokens, TLS material, and production configuration examples. |
| 40 | +- Write comments only when they explain why code or docs structure is shaped a certain way. Put comments before the relevant block instead of scattering them inside it. |
| 41 | + |
| 42 | +## Troubleshooting |
| 43 | + |
| 44 | +- If setup, QA, spelling, links, or docs builds fail, check docs first, then compare with CI. If commands diverge, follow CI. |
0 commit comments