Add slash command "/format" to automatically format PRs#646
Add slash command "/format" to automatically format PRs#646seisman merged 12 commits intoGenericMappingTools:masterfrom seisman:master
Conversation
weiji14
left a comment
There was a problem hiding this comment.
Ok, I've added an APP_ID and APP_PRIVATE_KEY secret to the PyGMT repo which generates a token using the GenericMappingTools bot account:
See if the suggested changes work, not sure if it will work on your personal branch though @seisman, since the APP is installed only on GenericMappingTools/pygmt.
Co-authored-by: Wei Ji <23487320+weiji14@users.noreply.github.com>
Co-authored-by: Wei Ji <23487320+weiji14@users.noreply.github.com>
weiji14
left a comment
There was a problem hiding this comment.
How about modifying the "Run make format and make check to make sure the code follows the style guide." line in https://github.com/GenericMappingTools/pygmt/blob/master/.github/PULL_REQUEST_TEMPLATE.md to mention the new /format command?
|
|
Perhaps we can add a note in the template like: |
Co-authored-by: Wei Ji <23487320+weiji14@users.noreply.github.com>
The workflow ran on every GitHub issue and pull request comments. This patch ensures that the the slash command dispatch workflow is triggered by Pull Request comments only. Patches #646.
) The workflow ran on every GitHub issue and pull request comments. This patch ensures that the the slash command dispatch workflow is triggered by Pull Request comments only. Patches #646.
…nericMappingTools#1248) The workflow ran on every GitHub issue and pull request comments. This patch ensures that the the slash command dispatch workflow is triggered by Pull Request comments only. Patches GenericMappingTools#646.

Description of proposed changes
This PR adds a special github action to enable slash commands in comments. With the feature enabled, anyone, who have written permission to a pull request, can write
/formatat the first line of a comment to trigger the "format" action, which can format the codes automatically.See #645 for context.
Reminders
make formatandmake checkto make sure the code follows the style guide.doc/api/index.rst.