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

Chore: Add support for new issue experience (fixes #3646) #3647

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

guywillis
Copy link
Contributor

Fixes #3646

Chore

  • Add new issue_template.md file with YAML frontmatter
  • Add new config.yml file to disable blank template

@guywillis guywillis added the bug label Jan 23, 2025
@guywillis guywillis self-assigned this Jan 23, 2025
Copy link
Contributor

Choose a reason for hiding this comment

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

👀

Copy link
Contributor

@swashbuck swashbuck left a comment

Choose a reason for hiding this comment

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

👍

@swashbuck
Copy link
Contributor

@guywillis Are you going to include the pull request templates as part of this PR?

@guywillis
Copy link
Contributor Author

@swashbuck I hadn't planned to as it's not part of the 'new issue experience' feature at present but I can certainly see the benefit of implementing it in advance alongside this work.

From reading https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/creating-a-pull-request-template-for-your-repository it doesn't appear as though pull request templates have been implemented in quite the same way as issue templates. In that:

To create multiple pull request templates and use the template query parameter to specify a template to fill the pull request body, type .github/PULL_REQUEST_TEMPLATE/, then the name of your pull request template. For example, .github/PULL_REQUEST_TEMPLATE/pull_request_template.md. You can also store multiple pull request templates in a PULL_REQUEST_TEMPLATE subdirectory within the root or docs/ directories. For more information, see Using query parameters to create a pull request.

The more information link states that:

https://github.com/octo-org/octo-repo/compare/main...my-branch?quick_pull=1&template=issue_template.md creates a pull request with a template in the pull request body. The template query parameter works with templates stored in a PULL_REQUEST_TEMPLATE subdirectory within the root, docs/ or .github/ directory in a repository.

The PR template is automatically pulled into the PR when the template file lives in .github/pull_request_template.md. A PR template that lives in .github/PULL_REQUEST_TEMPLATE/pull_request_template.md has to be manually navigated to via the URL in order to populate the PR with the template information.

I concluded that requiring users to amend the URL to use a template when creating a pull request was a step too far at this stage. With that being said, if GitHub implements the PR template in the same fashion as the 'new issue experience' template then it would be beneficial to get that included at this stage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Needs Reviewing
Development

Successfully merging this pull request may close these issues.

Add support for new issue experience
4 participants