Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions editor/branching-and-publishing.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
keywords: ["editor", "branch", "publish", "pull request", "preview", "git", "merge", "deploy"]
---

The web editor autosaves everything as you type, but your changes are only live when you choose to publish them.

Check warning on line 7 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L7

Did you really mean 'autosaves'?

What happens when you publish depends on two things: **which branch you're on** and **whether that branch requires pull requests**.

## Saving versus publishing

**Saving** happens automatically. Your edits are stored on Mintlify's servers and persist across browser tabs, devices, and network interruptions.

Check warning on line 13 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L13

In general, use active voice instead of passive voice ('are stored').

**Publishing** commits your changes to your Git repository. Click the **Publish** button in the toolbar to open the publish menu, save your changes as a Git commit, and create a pull request.

Expand Down Expand Up @@ -38,7 +38,7 @@
- **Create branch**: Moves your pending changes to a new feature branch when you're on a protected deployment branch.
- **Create pull request**: Opens a pull request targeting your deployment branch.

If there are no pending changes, the publish and save actions are disabled.

Check warning on line 41 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L41

In general, use active voice instead of passive voice ('are disabled').

<Note>
Your live site updates after Mintlify builds and deploys your changes. This typically takes 30 seconds to a few minutes. Check the deployment status on your [dashboard](https://dashboard.mintlify.com).
Expand All @@ -48,7 +48,7 @@

**Edit directly on your deployment branch** if you do not use a Git-based workflow.

**Create a branch** when you use a docs-as-code workflow where each change to your content is made on a separate branch.

Check warning on line 51 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L51

In general, use active voice instead of passive voice ('is made').

## Create and switch branches

Expand All @@ -70,9 +70,13 @@
1. Click the branch to switch to it.

<Note>
Switching branches while you have unpublished changes will prompt you to bring those changes to the new branch or leave them behind. Changes left behind remain on your original branch.

Check warning on line 73 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L73

Avoid using 'will'.
</Note>

<Tip>
To copy a branch name, hover over the branch in the dropdown and click the copy icon. This is useful when sharing the branch with teammates or referencing it in a pull request.
</Tip>

## Preview your changes

Every time you save changes to a feature branch, Mintlify builds a preview deployment—a temporary URL where your changes render exactly as they look when published.
Expand Down Expand Up @@ -108,13 +112,13 @@

When a pull request is open for the current branch, the publish menu shows its review status:

- **Approved**: The pull request has been approved and is ready to merge.

Check warning on line 115 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L115

In general, use active voice instead of passive voice ('been approved').
- **Changes requested**: A reviewer has requested changes before the pull request can merge.
- **Awaiting review**: The pull request is waiting for a reviewer.

Click **View request** to open the pull request in your Git provider.

When the pull request is approved, click **Merge and publish** to merge and deploy directly from the editor. The editor switches to your deployment branch after merging.

Check warning on line 121 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L121

In general, use active voice instead of passive voice ('is approved').

<Tip>
Configure branch protection rules in your Git provider to require pull requests. See [About protected branches](https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches) in the GitHub docs or [Protected branches](https://docs.gitlab.com/user/project/repository/branches/protected/) in the GitLab docs.
Expand All @@ -140,13 +144,13 @@

## Collaborate in real time

When multiple people open the same page on the same branch, they edit together in real time. Each person's cursor and edits are visible to everyone, with avatars shown in the toolbar.

Check warning on line 147 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L147

Use 'Cursor' instead of 'cursor'.

- Changes from all collaborators merge automatically. Two people editing the same section won't create conflicts.
- Undo only affects your own edits.
- If you lose your connection, edits save locally and sync when you reconnect.

When the [Mintlify agent](/agent) edits a page through the API or MCP, it appears in the editor like any other collaborator. You see the agent's avatar in the toolbar and a live cursor at its most recent edit location. The cursor clears automatically after the agent finishes.

Check warning on line 153 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L153

Use 'Cursor' instead of 'cursor'.

Check warning on line 153 in editor/branching-and-publishing.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

editor/branching-and-publishing.mdx#L153

Use 'Cursor' instead of 'cursor'.

## Git sync

Expand Down
Loading