From 768c4151ee963e39313a95a3d7cce30bdd4e0484 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Dunglas?= Date: Fri, 23 Oct 2026 09:14:40 +0200 Subject: [PATCH 1/2] docs: fix invalid anchors and blockquote in translations --- docs/cn/static.md | 2 +- docs/fr/hot-reload.md | 2 +- docs/fr/static.md | 2 +- docs/it/static.md | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/cn/static.md b/docs/cn/static.md index 7b81cc1bf7..405a20771b 100644 --- a/docs/cn/static.md +++ b/docs/cn/static.md @@ -97,7 +97,7 @@ docker run --rm -v "$PWD/output:/output" -e OUTPUT_DIR=/output -e SPC_LOGS_DIR=/ > 如果 `XCADDY_ARGS` 为空或未设置,则默认包含 cbrotli、Mercure 和 Vulcain 模块。 > 如果您自定义 `XCADDY_ARGS` 的值,则必须显式包含它们才能使其生效。 -另请参阅如何 [自定义 FrankenPHP 静态构建](#customizing-the-frankenphp-static-build) +另请参阅如何 [自定义 FrankenPHP 静态构建](#自定义-frankenphp-静态构建) ### GitHub token diff --git a/docs/fr/hot-reload.md b/docs/fr/hot-reload.md index ae8ad1f00b..295012ecfa 100644 --- a/docs/fr/hot-reload.md +++ b/docs/fr/hot-reload.md @@ -23,7 +23,7 @@ Selon votre configuration, le navigateur va soit : Pour activer le hot reload, activez Mercure, puis ajoutez la sous-directive `hot_reload` à la directive `php_server` dans votre `Caddyfile`. > [!WARNING] - +> > Cette fonctionnalité est destinée **uniquement aux environnements de développement**. > N'activez pas `hot_reload` en production, car cette fonctionnalité n'est pas sécurisée (expose des détails internes sensibles) et ralentit l'application. diff --git a/docs/fr/static.md b/docs/fr/static.md index 937f0a1922..1e7a6b14d8 100644 --- a/docs/fr/static.md +++ b/docs/fr/static.md @@ -97,7 +97,7 @@ Dans cet exemple, nous ajoutons le module de cache HTTP [Souin](https://souin.io > Les modules cbrotli, Mercure et Vulcain sont inclus par défaut si `XCADDY_ARGS` est vide ou n'est pas défini. > Si vous personnalisez la valeur de `XCADDY_ARGS`, vous devez les inclure explicitement si vous voulez qu'ils soient inclus. -Voir aussi comment [personnaliser la construction statique de FrankenPHP](#customizing-the-frankenphp-static-build) +Voir aussi comment [personnaliser la construction statique de FrankenPHP](#personnalisation-de-la-construction-statique-de-frankenphp) ### Jeton GitHub diff --git a/docs/it/static.md b/docs/it/static.md index 2e95128ff9..5c24db6f18 100644 --- a/docs/it/static.md +++ b/docs/it/static.md @@ -96,7 +96,7 @@ In questo esempio, aggiungiamo il modulo cache HTTP [Souin](https://souin.io) pe > I moduli cbrotli, Mercure e Vulcain sono inclusi per impostazione predefinita se `XCADDY_ARGS` è vuoto o non impostato. > Se personalizzi il valore di `XCADDY_ARGS`, devi includerli esplicitamente se desideri che siano inclusi. -Scopri anche come [personalizzare la build statica di FrankenPHP](#customizing-the-frankenphp-static-build) +Scopri anche come [personalizzare la build statica di FrankenPHP](#personalizzare-la-build-statica-di-frankenphp) ### Token GitHub From ce9ea68b048f3b0058cba894cdbe6356279dc072 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Dunglas?= Date: Fri, 23 Oct 2026 11:29:57 +0200 Subject: [PATCH 2/2] ci: prevent invalid Markdown in generated translations --- .github/workflows/translate.yaml | 3 +-- docs/translate.php | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/translate.yaml b/.github/workflows/translate.yaml index 6830780ffc..4655bf76c5 100644 --- a/.github/workflows/translate.yaml +++ b/.github/workflows/translate.yaml @@ -44,13 +44,12 @@ jobs: php ./docs/translate.php "$MD_FILES" - name: Run Linter if: steps.md_files.outputs.found == 'true' - continue-on-error: true uses: super-linter/super-linter/slim@2da136927bd4a73596db63044b504547c62cb854 # v9.0.0 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} LINTER_RULES_PATH: / MARKDOWN_CONFIG_FILE: .markdown-lint.yaml - VALIDATE_NATURAL_LANGUAGE: false + VALIDATE_MARKDOWN: true FIX_MARKDOWN: true - name: Create Pull Request if: steps.md_files.outputs.found == 'true' diff --git a/docs/translate.php b/docs/translate.php index c587b6b863..1d8900fc77 100644 --- a/docs/translate.php +++ b/docs/translate.php @@ -27,6 +27,7 @@ * **General Links:** You must not translate link URLs, only the link text. * **php.net Exception:** You must rewrite all `php.net` URLs to use their language-agnostic format by removing the language segment (e.g., change `https://www.php.net/manual/en/function.echo.php` to `https://www.php.net/manual/function.echo.php`). * **Anchors:** You may translate anchors to translation pages (e.g., `config.md#translated-anchor`), but keep existing anchors as they are. +* **Same-page Anchors:** Headings are translated, so every link to a heading of the same document (e.g., `#customizing-the-frankenphp-static-build`) must use the anchor GitHub generates from the translated heading (lowercase, spaces replaced by hyphens, punctuation removed). * **Content Integrity:** You must not add or remove any content; only translate what is present. * **Accuracy:** You must ensure that the translation is accurate and faithful to the original meaning. * **Style:** You must write in a natural and fluent style appropriate for technical documentation.