Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to show branch in PR title #332

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

JakobDev
Copy link
Contributor

f-e-d-c is currently used by com.riverbankcomputing.PyQt.BaseApp on 3 different branches. Having the branch (e.g. 5.15-22.08 or 6.3) would make it possible to see which branch is targeted directly in the Notification or the PR list.

Note: This is currently not tested

@@ -247,6 +248,11 @@ def open_pr(

head = "{}:{}".format(repo.owner.login, change.branch)
pr_message = ((change.body or "") + "\n\n" + DISCLAIMER).strip()

if branch_title:
Copy link
Contributor

Choose a reason for hiding this comment

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

or something like:

Suggested change
if branch_title:
if base not in ('master', 'beta'):

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I personal prefer a argument, so the User can decide if he want it or not. There may be someone who uses f-e-d-c on the master and the beta branch and want to know, if a PR goes against the master or the beta branch.

@gasinvein
Copy link
Collaborator

gasinvein commented Oct 13, 2022

I wonder if it could be more generic - instead of a boolean option determining whether or not to put branch name into PR title, use a string option with PR title template, with $updated as the default, and ability to set it to something like [$branch] $updated

@@ -210,6 +210,7 @@ def open_pr(
change: CommittedChanges,
manifest_checker: manifest.ManifestChecker = None,
fork: t.Optional[bool] = None,
branch_title: t.Optional[bool] = None,
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
branch_title: t.Optional[bool] = None,
branch_title: bool = False,

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.

3 participants