Skip to content

Check auto-merge commit title #238

@AlekSi

Description

@AlekSi

// checkAutoMerge checks if PR's auto-merge is enabled.
func checkAutoMerge(_ *githubactions.Action, pr *graphql.PullRequest, community bool) error {
if pr.Closed || pr.AutoMerge {
return nil
}
msg := `PR should have auto-merge enabled.`
if community {
msg += ` Don't worry, maintainers will enable it for you.`
}
return errors.New(msg)
}

conform-pr's auto-merge checker should check that the commit_title property matches PR's subject number plus the PR number with # and brackets. That is to ensure that auto-merge generates the right commit subject line after the PR title is edited.

Metadata

Metadata

Assignees

No one assigned

    Labels

    code/featureSome feature is not implemented yetgood first issueGood issues for new external contributors

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions