|
| 1 | +# CLAUDE.md for Deckhouse Development Platform |
| 2 | + |
| 3 | +This repository contains Hugo-based documentation for the Deckhouse Development Platform. |
| 4 | + |
| 5 | +## Run the docs site locally |
| 6 | + |
| 7 | +```bash |
| 8 | +make up # start via Docker Compose |
| 9 | +make down # stop and remove containers |
| 10 | +``` |
| 11 | + |
| 12 | +- EN: <http://localhost/products/development-platform/documentation/> |
| 13 | +- RU: <http://ru.localhost/products/development-platform/documentation/> |
| 14 | + |
| 15 | +All targets: |
| 16 | + |
| 17 | +| Target | Purpose | |
| 18 | +|--------|---------| |
| 19 | +| `make up` | Start docs via Docker Compose | |
| 20 | +| `make down` | Stop and remove containers | |
| 21 | +| `make serve` | Start Hugo dev server locally without Docker | |
| 22 | +| `make build` | Build the site to `./public` | |
| 23 | +| `make lint-markdown` | Lint Markdown files | |
| 24 | +| `make lint-markdown-fix` | Lint and auto-fix Markdown files | |
| 25 | +| `make mod` | Clean up Hugo modules (`hugo mod tidy`) | |
| 26 | + |
| 27 | +## Editorial policy |
| 28 | + |
| 29 | +The normative style guide and glossary are at **<https://pp.flant.ru/llms.txt>**. |
| 30 | +Fetch it before writing or reviewing documentation. |
| 31 | + |
| 32 | +## Documentation style |
| 33 | + |
| 34 | +- Write concise technical text with clear user value. |
| 35 | +- No first-level headings (`#`) in documentation files. Minimum level is `##`. |
| 36 | +- Prefer short paragraphs and structured lists. |
| 37 | +- For emphasis, use **bold**; avoid unnecessary italic. |
| 38 | +- Keep instructions actionable and testable. |
| 39 | +- In command examples use `d8 k` instead of `kubectl`. |
| 40 | +- YAML snippets must be syntactically valid. |
| 41 | +- Markdown ordered lists: use `1.` for every item (not `1.`, `2.`, `3.`). |
| 42 | + |
| 43 | +### Inline code |
| 44 | + |
| 45 | +Use inline code for: parameters, module names, commands, file paths, HTTP codes. |
| 46 | +Do not overuse it for resource type names in narrative text. |
| 47 | +Do not wrap values inside YAML files in backticks — YAML values are already code context. |
| 48 | + |
| 49 | +### Links |
| 50 | + |
| 51 | +- Use meaningful link anchors (avoid "here" or "тут"). |
| 52 | +- Links to project pages must be relative. |
| 53 | +- Links to Deckhouse Kubernetes Platform docs must be absolute without domain (`/products/kubernetes-platform/documentation/v1/...`). |
| 54 | + |
| 55 | +### Code blocks |
| 56 | + |
| 57 | +Every fenced code block must have an explicit language tag from the Hugo/Chroma list. |
| 58 | +If the needed language is absent, use `text` or `plain`. |
| 59 | + |
| 60 | +Common tags: `bash`, `yaml`, `json`, `go`, `go-html-template`, `text`, `plain`. |
| 61 | +Full list: see `.cursor/rules/docs/hugo-supported-codeblock-languages.mdc`. |
| 62 | + |
| 63 | +### Hugo shortcodes |
| 64 | + |
| 65 | +```go-html-template |
| 66 | +{{< alert level="warning" >}} |
| 67 | +Message text. |
| 68 | +{{< /alert >}} |
| 69 | +``` |
| 70 | + |
| 71 | +Alert levels: `info`, `warning`, `danger`. |
| 72 | + |
| 73 | +```go-html-template |
| 74 | +{{< tabs name="uniq_name" >}} |
| 75 | +{{% tab name="Tab 1" %}}Content{{% /tab %}} |
| 76 | +{{% tab name="Tab 2" %}}Content{{% /tab %}} |
| 77 | +{{< /tabs >}} |
| 78 | +``` |
| 79 | + |
| 80 | +```go-html-template |
| 81 | +{{% details "Summary..." %}} |
| 82 | +Markdown content. |
| 83 | +{{% /details %}} |
| 84 | +``` |
| 85 | + |
| 86 | +### Release notes (`content/documentation/release-notes/`) |
| 87 | + |
| 88 | +- Under a heading, if the only body content is a single bullet — write plain prose, not a list. |
| 89 | +- Keep lists only when there are two or more top-level bullets under the same heading. |
| 90 | + |
| 91 | +## Terminology |
| 92 | + |
| 93 | +Full glossary: <https://pp.flant.ru/llms.txt> (see "Glossary" section). |
| 94 | + |
| 95 | +Key rules: |
| 96 | +- `K8s` (uppercase K) |
| 97 | +- Use "узел", not "нода" |
| 98 | +- Use "веб-интерфейс" |
| 99 | +- Use `IP-адрес` |
| 100 | +- Use "файлы cookie" |
| 101 | +- Avoid "платформа Deckhouse"; use explicit product names (e.g. Deckhouse Kubernetes Platform) |
| 102 | +- Deckhouse module names must be in lowercase kebab-case. |
| 103 | +- Do not translate product names and abbreviations that the glossary keeps in EN (e.g. `RBAC`) |
| 104 | + |
| 105 | +Mixed EN/RU compound terms use a hyphen: `S3-бакет`, `managed-сервис`, `master-узел`, `HTTP-протокол`. |
| 106 | + |
| 107 | +## Russian text style |
| 108 | + |
| 109 | +In Russian instructional text, always use the imperative вы-form: |
| 110 | +- «создайте», not «создаем» |
| 111 | +- «нажмите», not «нажимаем» |
| 112 | +- «перейдите», not «переходим» |
| 113 | + |
| 114 | +This applies to all step-by-step instructions, quickstart guides, and procedural text. |
| 115 | + |
| 116 | +## Front matter |
| 117 | + |
| 118 | +Required fields: `title`, `description` (concise, unique, not a copy of title). |
| 119 | + |
| 120 | +- Related links: use `params.relatedLinks` in front matter; do not add manual "Related links" sections in the Markdown body. |
| 121 | + |
| 122 | +## EN/RU parity |
| 123 | + |
| 124 | +- Russian files use the `.ru.md` suffix only (not `.RU.md`, `_RU.md`). |
| 125 | +- For each change relevant to both languages, update both files. |
| 126 | +- Do not leave EN/RU pairs semantically diverged unless the change is intentionally language-specific. |
| 127 | +- Localized media: `image1.jpg` (EN) / `image1.ru.jpg` (RU). |
0 commit comments