only create a single PR per target repo #38
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this amount of shell is still reasonable :)
- name: Create Pull Request | ||
if: ${{ env.NEEDS_UPDATE == 1 }} | ||
uses: peter-evans/create-pull-request@052fc72b4198ba9fbc81b818c6e1859f747d49a8 #v3.8.2 | ||
with: | ||
commit-message: ${{ env.COMMIT_MSG }} | ||
title: ${{ env.PR_TITLE }} | ||
title: "sync: ${{ github.event.client_payload.github_event.pull_request.title }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how will this behave if the PR already exists? Will it overwrite the existing title, or leave the original title?
I think either can be somewhat confusing, if the title is specific to a single commit. Maybe we could name it something like web3-bot: sync CI setup
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Think of it as a force-push, so everything will be overwritten.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we could name it something like web3-bot: sync CI setup.
This is tricky. We just generalized the workflow to cover all kinds of files, so I'm not sure what do do here.
In #36 (comment), @mvdan suggested to only create a single PR per target repo, consisting of multiple commits, one for each file that was changed.
This will significantly reduce the noise of introducing this workflow to new repositories, as we're only opening a single PR instead of 4. It will also allow us to push changes to more repositories before triggering GitHub's abuse detection mechanism.