Skip to content

Execution Modes

Auto Merge supports six execution modes, allowing gradual adoption from read-only observation to full automation.

Set the mode via CLI flag: --mode=<Mode>

Mode Labels Rebase Cancel Pipelines Cancel Auto-Merge Merge Use Case
DryRun — — — — — Test without changes
OnlyLabels yes — — — — Visualize MR status only
RebaseOnly yes yes — — — Keep MRs up-to-date
NoMerge yes yes yes yes — Prepare MRs, let humans merge
NoPipelineCancellation yes yes — — yes Full automation, all pipelines run
Run yes yes yes yes yes Full automation with pipeline optimization

“Cancel Auto-Merge” disables GitLab’s built-in “merge when pipeline succeeds” flag on MRs, preventing double-merges. Auto Merge controls the merge queue — GitLab’s native auto-merge must not interfere.

Default: DryRun

  1. Start with DryRun — observe what Auto Merge would do without any changes
  2. Switch to OnlyLabels — adds status labels to MRs, giving your team visibility
  3. Enable RebaseOnly — automatically rebases MRs, reducing manual work
  4. Go to Run — full automation with merging, rebasing, and pipeline management
Terminal window
# Start in observation mode
docker run ... neckarit/gitlab-auto-merge:latest --mode=DryRun
# Later, enable full automation
docker run ... neckarit/gitlab-auto-merge:latest --mode=Run