Skip to content

[feature not live] docs(merge-queue): document configurable label commands for enqueueing#661

Draft
samgutentag wants to merge 1 commit into
mainfrom
sam-gutentag/mq-configurable-enqueue-label-clean
Draft

[feature not live] docs(merge-queue): document configurable label commands for enqueueing#661
samgutentag wants to merge 1 commit into
mainfrom
sam-gutentag/mq-configurable-enqueue-label-clean

Conversation

@samgutentag
Copy link
Copy Markdown
Member

Adds documentation for the Label Commands feature (trunk2 PR #3956, shipped in v175).

Changes

  • Documents label-based enqueue/cancel as a submission method in the reference page
  • Adds a Label Commands section covering how to enable the feature, configure the enqueueing label, and how apply/remove works

Context


Generated by Claude Code

Documents the Label Commands setting (trunk2 PR #3956, ships in v175):
- enqueueing by label as a submission method
- how to enable and configure the enqueueing label in Settings
- the apply/remove behavior table

https://github.com/trunk-io/trunk2/pull/3956

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@trunk-staging-io
Copy link
Copy Markdown

Merging to main in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

After your PR is submitted to the merge queue, this comment will be automatically updated with its status. If the PR fails, failure details will also be posted here

@claude
Copy link
Copy Markdown
Contributor

claude Bot commented May 14, 2026

Claude finished @samgutentag's task in 1m 41s —— View job


Review summary

  • Read the changed file
  • Review the diff
  • Check related context (heading conventions in reference.md, terminology in advanced-settings.md, "enqueueing" spelling across merge-queue/)
  • Post inline comments for issues
  • Post final review summary

Result: non-blocking. The new content is clear, accurate, and well-placed. I left 4 inline comments — all polish, none required to ship.

Findings

  1. Heading case (line 43–47) — ## Label Commands / ### Enabling Label Commands use Title Case, but every other heading in reference.md is sentence case (## Custom merge commit titles, ### How it works, ### Example). The neighboring advanced-settings.md is mixed, so this is a file-local consistency point, not a repo-wide one.
  2. "Label Commands" vs "label commands" — the term flips between Title Case (header, lines 45/49/51, link text on line 23) and lowercase (prose on lines 23 and 41). Pick one. If you take the heading suggestion above, lowercase everything; otherwise normalize the prose to Title Case.
  3. Missing parallel cross-reference (line 41) — line 23 links to the new section, the matching cancellation bullet doesn't. Easy parallelism win.
  4. Vague configuration location (line 51) — "you can configure the enqueueing label name" doesn't say where. Probably the same panel mentioned one sentence earlier — worth stating explicitly. Bonus: clarify whether renaming the label retroactively affects PRs already carrying the old one.
  5. Precondition visibility (line 60) — "The label must already exist… Trunk does not create the label automatically" is a silent-failure trap and currently styled as plain prose, right before an info hint. Consider promoting it to {% hint style="warning" %} so it's not visually outranked by the less-critical note below it.

Things that look good

  • Spelling of enqueueing matches existing usage across merge-queue/ (4 prior hits).
  • **Merge Queue Settings** matches the heading used in merge-queue/administration/advanced-settings.md:129.
  • The new bullets are inserted in the right places (parallel to existing submission/cancellation methods).
  • The action/effect table is a nice touch — clearer than prose for two symmetric operations.
  • PR title flagging [feature not live] is helpful context for reviewers.

Branch: sam-gutentag/mq-configurable-enqueue-label-clean

Comment on lines +43 to +47
## Label Commands

Label Commands let you enqueue and cancel PRs in the Merge Queue by applying or removing a GitHub label, without leaving a comment or using the CLI.

### Enabling Label Commands
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Heading case inconsistent with rest of file. Every other ## and ### heading in reference.md uses sentence case (## Submitting and cancelling pull requests, ## Custom merge commit titles, ### How it works, ### Example), but the new headings use Title Case. Consider matching the file's existing convention:

Suggested change
## Label Commands
Label Commands let you enqueue and cancel PRs in the Merge Queue by applying or removing a GitHub label, without leaving a comment or using the CLI.
### Enabling Label Commands
## Label commands
Label commands let you enqueue and cancel PRs in the Merge Queue by applying or removing a GitHub label, without leaving a comment or using the CLI.
### Enabling label commands

If you do this, also lowercase "Label Commands" in prose on lines 49 and 51 (and the link text on line 23) so the term is treated consistently as a feature description rather than a proper noun.

Fix this →

trunk merge cancel <pr-number>
```

* Removing the configured enqueueing label from a pull request (when label commands are enabled).
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing cross-reference for parallelism with line 23. The submission bullet (line 23) helpfully links to the Label Commands section, but the matching cancellation bullet here doesn't. A reader who lands on the cancellation list first won't know where to learn more. Suggest mirroring the submission bullet:

Suggested change
* Removing the configured enqueueing label from a pull request (when label commands are enabled).
* Removing the configured enqueueing label from a pull request (when label commands are enabled — see [Label Commands](#label-commands) below).


Label Commands are configured per merge queue instance in **Merge Queue Settings** > **Label Commands**. Only organization admins can change this setting.

When Label Commands are enabled, you can configure the enqueueing label name. The default label is `trunk-merge-queue-submit`.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vague on where to configure the label name. "You can configure the enqueueing label name" implies a setting somewhere, but doesn't say where. Is it the same Merge Queue Settings > Label Commands location mentioned in the previous sentence, or somewhere else? Consider making it explicit, e.g.:

When enabled, you can set a custom label name in the same panel. The default is trunk-merge-queue-submit.

Also worth confirming whether changing the label name applies retroactively (do PRs already carrying the old label get cancelled? does it require a label to exist beforehand, per line 60?). If there's a known answer, surfacing it here would save a support ticket.

| Apply the enqueueing label to a PR | Submits the PR to the Merge Queue |
| Remove the enqueueing label from a PR | Cancels the PR from the queue |

The label must already exist in your GitHub repository. Trunk does not create the label automatically.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider promoting to a warning callout for visibility. This is a precondition that, if missed, will silently break the feature — users may assume Trunk creates the label and wonder why nothing happens when they apply it. The next paragraph is already a {% hint style="info" %}, so the contrast in style suggests this line is less important than it actually is. Suggest:

Suggested change
The label must already exist in your GitHub repository. Trunk does not create the label automatically.
{% hint style="warning" %}
The label must already exist in your GitHub repository. Trunk does not create the label automatically.
{% endhint %}

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Auto-approved: Claude code review passed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants