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

Prevent PR template insertion when the textarea is already populated #49

Closed
blakegearin opened this issue Jul 12, 2023 · 10 comments
Closed

Comments

@blakegearin
Copy link
Contributor

Steps to Reproduce

  1. Go to a "Open a pull request" page
  2. The extension will fill in the PR template
  3. Type some information to prepare the PR for review
  4. Reload the page
  5. The information will show in the textarea for a brief moment
  6. The extension will fill in the PR template, erasing previous work & effort 🙁
@RobQuistNL
Copy link
Owner

oof, that sounds nasty! Good suggestion. Will see if I have time to implement this, probably shouldn't be too hard!

@RobQuistNL
Copy link
Owner

Fixed in v1.3.0

@rishabh-sagar-20
Copy link

@RobQuistNL @blakegearin, this was the exact feature that has been working for me for the last 2 years. Now, the template doesn't even show up while creating a new PR :(

Is there any workaround?

@RobQuistNL
Copy link
Owner

hmm, can you make me some reproduction steps @rishabh-sagar-20 ?

@rishabh-sagar-20
Copy link

@RobQuistNL, when creating a new PR, GitHub automatically fills in the Title and Description fields using one of the initial commits from the branch. However, since we are now checking for empty values before applying the default template, this causes an issue because GitHub has already populated these fields. I recommend adding an option to control this behavior, which would help resolve the problem.

@blakegearin
Copy link
Contributor Author

@rishabh-sagar-20 Ctrl + A to select all of the description, then delete and refresh.

@RobQuistNL
Copy link
Owner

You mean there's a "PR Template" in the .github folder in the repo and thats not being overwritten by this extension?

In my opinion thats by design - I don't want to overwrite any repo specific PR templates.

Or are you talking about something else? If its the first case, maybe we can add a button to "force" the Github-Jira PR template.

@rishabh-sagar-20
Copy link

You mean there's a "PR Template" in the .github folder in the repo and thats not being overwritten by this extension?

In my opinion thats by design - I don't want to overwrite any repo specific PR templates.

Or are you talking about something else? If its the first case, maybe we can add a button to "force" the Github-Jira PR template.

@RobQuistNL, It's not a repository-specific template; GitHub fills it in during the initial page load. The "force" button should work.

@rishabh-sagar-20
Copy link

@rishabh-sagar-20 Ctrl + A to select all of the description, then delete and refresh.

@blakegearin, it was not working in my case somehow. I will give it a try again.

@RobQuistNL
Copy link
Owner

Is this repository you talk about public, so I can check it out? Because if what you're saying is happening it means it shouldn't work at all for any PR. 🤔

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

No branches or pull requests

3 participants