From 65faa0416659591905cd0bc12a0e62719652ea92 Mon Sep 17 00:00:00 2001 From: "mintlify[bot]" <109931778+mintlify[bot]@users.noreply.github.com> Date: Thu, 20 Nov 2025 05:09:04 +0000 Subject: [PATCH 1/5] Update organize/mintignore.mdx --- organize/mintignore.mdx | 102 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 organize/mintignore.mdx diff --git a/organize/mintignore.mdx b/organize/mintignore.mdx new file mode 100644 index 000000000..26b8732ac --- /dev/null +++ b/organize/mintignore.mdx @@ -0,0 +1,102 @@ +--- +title: ".mintignore" +description: "Exclude files and directories from your Mintlify build." +keywords: ["mintignore", "ignore files", "exclude files", "build optimization"] +--- + +Use a `.mintignore` file to exclude files and directories from your Mintlify build process. This is useful for keeping your documentation clean by excluding drafts, temporary files, or other content you don't want to publish. + +## Creating a `.mintignore` file + +Create a `.mintignore` file in the root of your documentation repository, next to your `docs.json` file. + +```text +/your-project + |- docs.json + |- .mintignore + |- index.mdx +``` + +## Syntax + +The `.mintignore` file follows the same syntax as `.gitignore` files. Each line specifies a pattern for files or directories to exclude. + +```text .mintignore +# Exclude draft files +drafts/ + +# Exclude temporary files +*.tmp +temp-*.mdx + +# Exclude specific files +notes.md +internal-docs.mdx +``` + +### Pattern rules + +- **Comments**: Lines starting with `#` are treated as comments +- **Empty lines**: Blank lines are ignored +- **Directories**: End patterns with `/` to match directories +- **Wildcards**: Use `*` to match any characters +- **Negation**: Start patterns with `!` to negate a previous ignore pattern + +## Default ignored files + +Mintlify automatically ignores the following files and directories, even without a `.mintignore` file: + +- `.git` +- `.github` +- `.claude` +- `.agents` +- `node_modules` + +You don't need to add these to your `.mintignore` file. + +## Examples + +### Exclude draft content + +```text .mintignore +# Ignore all draft files +drafts/ +*-draft.mdx +``` + +### Exclude work-in-progress files + +```text .mintignore +# Ignore WIP files +wip/ +*-wip.mdx +TODO.md +``` + +### Exclude internal documentation + +```text .mintignore +# Internal docs +internal/ +team-notes/ +*.internal.mdx +``` + +### Exclude specific file types + +```text .mintignore +# Exclude all markdown files in a specific directory +archive/*.md + +# Exclude backup files +*.bak +*~ +``` + +## Local development + +When running `mint dev`, changes to your `.mintignore` file require restarting the development server to take effect. + + +After modifying `.mintignore`, restart your local development server with `mint dev` to apply the changes. + From 51483e0745a57385ac978e64e2c780db103fd352 Mon Sep 17 00:00:00 2001 From: "mintlify[bot]" <109931778+mintlify[bot]@users.noreply.github.com> Date: Thu, 20 Nov 2025 05:09:16 +0000 Subject: [PATCH 2/5] Update docs.json --- docs.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs.json b/docs.json index f5154b6f8..5bdbb910f 100644 --- a/docs.json +++ b/docs.json @@ -40,7 +40,8 @@ "organize/settings", "organize/navigation", "organize/pages", - "organize/hidden-pages" + "organize/hidden-pages", + "organize/mintignore" ] }, { From 3c1a0eacddf49af06243e3b28153c322ef5d9b40 Mon Sep 17 00:00:00 2001 From: "mintlify[bot]" <109931778+mintlify[bot]@users.noreply.github.com> Date: Thu, 20 Nov 2025 05:09:23 +0000 Subject: [PATCH 3/5] Update docs.json --- docs.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs.json b/docs.json index 5bdbb910f..4517764c6 100644 --- a/docs.json +++ b/docs.json @@ -341,7 +341,8 @@ "zh/organize/settings", "zh/organize/navigation", "zh/organize/pages", - "zh/organize/hidden-pages" + "zh/organize/hidden-pages", + "zh/organize/mintignore" ] }, { From 8841ebbd260352fe19c38ead898a23a423c9b209 Mon Sep 17 00:00:00 2001 From: "mintlify[bot]" <109931778+mintlify[bot]@users.noreply.github.com> Date: Thu, 20 Nov 2025 05:09:30 +0000 Subject: [PATCH 4/5] Update docs.json --- docs.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs.json b/docs.json index 4517764c6..d7bbfae96 100644 --- a/docs.json +++ b/docs.json @@ -642,7 +642,8 @@ "es/organize/settings", "es/organize/navigation", "es/organize/pages", - "es/organize/hidden-pages" + "es/organize/hidden-pages", + "es/organize/mintignore" ] }, { From 82863e4a7da3e7c383e76dc56f49ae74dac6069f Mon Sep 17 00:00:00 2001 From: "mintlify[bot]" <109931778+mintlify[bot]@users.noreply.github.com> Date: Thu, 20 Nov 2025 05:09:37 +0000 Subject: [PATCH 5/5] Update docs.json --- docs.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs.json b/docs.json index d7bbfae96..a69f8d23d 100644 --- a/docs.json +++ b/docs.json @@ -943,7 +943,8 @@ "fr/organize/settings", "fr/organize/navigation", "fr/organize/pages", - "fr/organize/hidden-pages" + "fr/organize/hidden-pages", + "fr/organize/mintignore" ] }, {