Skip to content

Skip Dependabot auto-merge while the repository disallows it - #81

Merged
imanimanyara merged 1 commit into
mainfrom
fix/dependabot-auto-merge-guard
Oct 13, 2026
Merged

imanimanyara merged 1 commit into
mainfrom
fix/dependabot-auto-merge-guard

Conversation

@imanimanyara

@imanimanyara imanimanyara commented Oct 13, 2026 •

Copy link
Copy Markdown
Member

gh pr merge --auto fails with "Auto merge is not allowed for this repository" while the repository's Allow auto-merge setting is off. That turns the dependabot job red on every Dependabot pull request.

This copies the guard from laranail/license-kit#19 unchanged, so the workflows do not diverge:

  • A new step reads allow_auto_merge from the API.
  • When the setting is off, the step posts a notice and leaves the pull request for a manual merge.
  • The merge step now runs only when the setting is on. This variant of the workflow has one merge step, covering both patch and minor updates.

The repository setting is not changed.

This repository has auto-merge on today (allow_auto_merge: true), so nothing here is failing yet. The guard is added so the workflow matches the other copies, and so the job does not break if the setting is later turned off.

gh pr merge --auto fails with "Auto merge is not allowed for this
repository" while the repository setting is off, so the dependabot job
went red on every Dependabot pull request. Read allow_auto_merge first,
and when it is off, leave a notice and the pull request for a manual
merge.

The check step is copied verbatim from laranail/license-kit#19, and the
single merge step in this variant of the workflow is gated on it, so
the guard stays identical. The repository setting itself is unchanged.
Copilot AI balanced review requested due to automatic review settings October 13, 2026 13:05

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@imanimanyara
imanimanyara merged commit 09910b8 into main Oct 13, 2026
17 checks passed
@imanimanyara
imanimanyara deleted the fix/dependabot-auto-merge-guard branch October 13, 2026 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants