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 ability to leave a review comment #615

Open
renvrant opened this issue Aug 24, 2022 · 2 comments
Open

Add ability to leave a review comment #615

renvrant opened this issue Aug 24, 2022 · 2 comments
Labels
priority: p3 Desirable enhancement or fix. May not be included in next release. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.

Comments

@renvrant
Copy link

Thanks for stopping by to let us know something could be better!

PLEASE READ: If you have a support contract with Google, please create an issue in the support console instead of filing on GitHub. This will ensure a timely response.

Is your feature request related to a problem? Please describe.
This tool is extremely useful for managing dependencies across many repositories. However, in order to fully control dependency update tools like dependabot, you need to be able to leave review comments. These comments can order the bot to rebase, recreate, or ignore given dependency updates, which is pretty integral for managing a dependency update across many repos with varying degrees of commit traffic and general up-to-date-ness. You can see Dependabot Comments and Options in this demo repo for an example.
Describe the solution you'd like
Add a command to comment on PRs that match a given title
Describe alternatives you've considered
Forking or patching this repo to add this feature? 😅
Additional context
N/A

@renvrant renvrant added priority: p3 Desirable enhancement or fix. May not be included in next release. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. labels Aug 24, 2022
@alexander-fenster
Copy link
Contributor

Seems like a good idea! We never need it because we manage our bots using labels, but I can see how being able to leave review comment could be useful. The code change should not be hard, if I'm reading correctly, we'll need to pass a comment text here:

async approvePullRequest(pr: PullRequest) {
const owner = this.repository.owner.login;
const repo = this.repository.name;
const url = `/repos/${owner}/${repo}/pulls/${pr.number}/reviews`;
const result = await this.client.request({
url,
method: 'POST',
data: {event: 'APPROVE'},
});
return result.data;
}

as a body (API call documentation: https://docs.github.com/en/rest/pulls/reviews), and we can take it from the command line and probably add an optional parameter to processPRs.

Feel free to send a pull request :) I might be able to find some time and implement it, but I cannot promise that I can do it soon.

@alexander-fenster
Copy link
Contributor

Since we are starting using Cloud Build more and might want to mass-comment PRs with /gcbrun, let's maybe consider this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p3 Desirable enhancement or fix. May not be included in next release. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

No branches or pull requests

2 participants