From 79794f438f3a4f6262bce85e5c6845ecf2706019 Mon Sep 17 00:00:00 2001 From: WH-2099 Date: Sun, 12 Apr 2026 21:08:10 +0800 Subject: [PATCH 1/2] fix: block internal files from mintlify publish --- .mintignore | 14 ++++++++++++-- AGENTS.md | 5 ++++- CLAUDE.md | 50 +------------------------------------------------- 3 files changed, 17 insertions(+), 52 deletions(-) mode change 100644 => 120000 CLAUDE.md diff --git a/.mintignore b/.mintignore index aa610350e..46a640925 100644 --- a/.mintignore +++ b/.mintignore @@ -1,2 +1,12 @@ -writing-guides/ -tools/translate/config.json +# Root-level internal instructions +/AGENTS.md +/CLAUDE.md + +# Internal workflow and tooling directories +/.githooks/ +/tools/ +/writing-guides/ + +# Non-public utility files under public asset directories +/assets/migrate_weaviate_collections.py +/logo/convertor.html diff --git a/AGENTS.md b/AGENTS.md index 07c4908aa..116722d12 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -15,6 +15,9 @@ For task-specific guidance, see `writing-guides/index.md`. - Only edit the English section in `docs.json`. Translation sections sync automatically. - MDX files require `title` and `description` in YAML frontmatter. +- When adding or updating internal-only instructions, tooling, configs, or + other non-public files, ensure all paths that should not be exposed by + Mintlify are covered in `.mintignore`. - Never use `--no-verify` when committing. ## Repository Structure @@ -41,4 +44,4 @@ mintlify dev Local preview at localhost:3000 | `refactor` | Reorganization without content changes | `refactor: restructure knowledge base section` | | `translate` | Translation additions or updates | `translate: update Japanese workflow pages` | | `style` | Formatting-only changes | `style: fix heading levels in plugin guide` | -| `chore` | Dependencies, config | `chore: bump mintlify to 4.0.710` | \ No newline at end of file +| `chore` | Dependencies, config | `chore: bump mintlify to 4.0.710` | diff --git a/CLAUDE.md b/CLAUDE.md deleted file mode 100644 index f58873306..000000000 --- a/CLAUDE.md +++ /dev/null @@ -1,49 +0,0 @@ -# Dify Documentation Repository - -Documentation for Dify, built with Mintlify. English is the source language; -Chinese and Japanese translations are generated automatically. -Exception: `en/self-host/configuration/environments.mdx` is excluded from the translation pipeline and must be translated manually. - -## Before Any Documentation Task - -Read `writing-guides/index.md` to identify the correct skill and shared -references for your task. - -## Key Rules - -- Write in English only, except when specifically optimizing Chinese or - Japanese translations. -- Only edit the English section in `docs.json`. Translation sections sync - automatically. -- MDX files require `title` and `description` in YAML frontmatter. -- When writing about a feature, verify behavior against the Dify codebase, - not just existing docs. Existing docs may be outdated. -- For new features, the user may specify a development branch. Code on - development branches may be in flux—when behavior is ambiguous, ask - rather than assume. - -## Repository Structure - -en/, zh/, ja/ Documentation content (en is source) -writing-guides/ Style guide, formatting guide, glossary -tools/translate/ Translation pipeline and language-specific formatting -.claude/skills/ Documentation writing skills (auto-discovered) -docs.json Navigation structure - -## Development - -mintlify dev Local preview at localhost:3000 - -## Commit and PR Title Conventions - -{type}: {description} — lowercase, imperative, no trailing period, under 72 chars. - -| Type | When | Example | -|:-----|:-----|:--------| -| `docs` | New or updated content | `docs: add workflow node configuration guide` | -| `fix` | Typos, broken links, incorrect info | `fix: correct broken link in knowledge base page` | -| `feat` | Tooling or structural changes | `feat: add search index to knowledge section` | -| `refactor` | Reorganization without content changes | `refactor: restructure knowledge base section` | -| `translate` | Translation additions or updates | `translate: update Japanese workflow pages` | -| `style` | Formatting-only changes | `style: fix heading levels in plugin guide` | -| `chore` | Dependencies, config | `chore: bump mintlify to 4.0.710` | diff --git a/CLAUDE.md b/CLAUDE.md new file mode 120000 index 000000000..47dc3e3d8 --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1 @@ +AGENTS.md \ No newline at end of file From bd37933acf3a9065a8afc3352ee77a6af742da97 Mon Sep 17 00:00:00 2001 From: RiskeyL <7a8y@163.com> Date: Mon, 13 Apr 2026 13:18:33 +0800 Subject: [PATCH 2/2] fix: restore missing rules in AGENTS.md from CLAUDE.md --- AGENTS.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 116722d12..6bf0a6ed0 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,5 +1,7 @@ # Dify Documentation — AI Agent Instructions +Documentation for Dify, built with Mintlify. English is the source language; Chinese and Japanese translations are generated automatically. Exception: `en/self-host/configuration/environments.mdx` is excluded from the translation pipeline and must be translated manually. + For documentation tasks, read these guides before starting: 1. `writing-guides/style-guide.md` — Voice, tone, writing patterns @@ -10,14 +12,12 @@ For task-specific guidance, see `writing-guides/index.md`. ## Key Rules -- Write in English only, except when specifically optimizing Chinese - or Japanese translations. -- Only edit the English section in `docs.json`. Translation sections sync - automatically. +- Write in English only, except when specifically optimizing Chinese or Japanese translations. +- Only edit the English section in `docs.json`. Translation sections sync automatically. - MDX files require `title` and `description` in YAML frontmatter. -- When adding or updating internal-only instructions, tooling, configs, or - other non-public files, ensure all paths that should not be exposed by - Mintlify are covered in `.mintignore`. +- When writing about a feature, verify behavior against the Dify codebase, not just existing docs. Existing docs may be outdated. +- For new features, the user may specify a development branch. Code on development branches may be in flux—when behavior is ambiguous, ask rather than assume. +- When adding or updating internal-only instructions, tooling, configs, or other non-public files, ensure all paths that should not be exposed by Mintlify are covered in `.mintignore`. - Never use `--no-verify` when committing. ## Repository Structure