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 empty pull_request_template.md to enable PR template chooser #2409

Merged
merged 1 commit into from
Oct 24, 2024

Conversation

EwoutH
Copy link
Member

@EwoutH EwoutH commented Oct 24, 2024

We added two pull request templates in #2217, but those never showed up in the PR template chooser. Apparently a pull_request_template.md in .github is always needed, which can be blank.

See

Directly merging since that's the only way to see if this works.

@EwoutH EwoutH added the maintenance Release notes label label Oct 24, 2024
@EwoutH EwoutH merged commit 7c91d99 into main Oct 24, 2024
1 of 2 checks passed
@EwoutH
Copy link
Member Author

EwoutH commented Oct 24, 2024

Okay, apparently this does not exist (yet). In classical GitHub fashion, there's an issue open for over a year with over a hundred upvotes that's never once answered by any GitHub staff:

https://github.com/orgs/community/discussions/4620

@Corvince
Copy link
Contributor

Just FYI: I once created a PR through vscode and only (or at least) there did our templates show up.

@EwoutH
Copy link
Member Author

EwoutH commented Oct 24, 2024

Oh that's interesting (and useful). Curious how most people create Pull requests, through:

  • their IDEA
  • the git command line
  • a git GUI (like GitHub Desktop)
  • the github.com interface

I now added a hacky workaround, that works somewhat for the GitHub interface. The default pull_request_template.md now says:

Thanks for opening a PR! Please click the `Preview` tab and select a PR template:

- [🐛 Bug fix](?expand=1&template=bug.md)
- [🛠 Feature/enhancement](?expand=1&template=feature.md)

Which results in clickable links in your PR that you can use to directly get a pull request template.

image

But this might interfere with IDE implementations of this feature, like VS code.

Feel free to give feedback on this, if this interferes more than it adds we can remove it again.

@EwoutH EwoutH deleted the pr_template_chooser branch October 26, 2024 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Release notes label
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants