Replace the four-section dir layout with the revised flat-page spec: - Three-page nav: Libraries, Standards, Deploy. - libraries.md: live client-side fetch of the rethink-public org from the Gitea API, denylist-filtered, sorted table linking each repo, no version pins, graceful fallback on fetch/CORS failure. - standards.md: house coding standards. - deploy.md: deploy guide for rethink-net (services uid 1337, uid-agnostic Docker, paths/mounts, bind-mount permissions, read-only secrets). - index.md landing card grid updated for the three sections. - gitignore Playwright MCP artifacts. Verified: mkdocs build --strict clean; libraries fallback renders live. Signed-off-by: disqualifier <dev@disqualifier.me>
1.2 KiB
1.2 KiB
Coding Standards
The house standards every Rethink Studios project follows. They keep our code consistent, readable, and predictable across the whole suite.
File hygiene
- Files end with a single trailing newline (LF / Unix line endings).
- No trailing whitespace on any line.
Indentation
- 4 spaces by default.
- Respect language norms: TS/JS use 2 spaces, Go uses tabs.
- When editing an existing file, follow that file's existing indentation.
Docstrings and comments
- Public functions get a docstring. Style: lowercase-start, no trailing period.
- Keep inline comments minimal — prefer docstrings. Use an inline comment only where the code is genuinely complex.
- Each module/file states its scope and purpose via a module docstring (header string) — not a license or copyright header.
READMEs
Every library and project has a defined README covering:
- the install line,
- what it does,
- a usage example.
Linting and types
- flake8 clean, max line length 120.
- Type hints on public functions.
Error handling
- Fail loud — never swallow exceptions.
- Catch the specific exception, and log it.