BioDrop
BioDrop copied to clipboard
Change workflows to not push to main directly.
Fixes Issue
Closes #2756
Changes proposed
- [X] Changes workflow
releases.yml
to not push tomain
directly. More info below.
Check List (Check all the applicable boxes)
- [X] My code follows the code style of this project.
- [ ] My change requires changes to the documentation.
- [ ] I have updated the documentation accordingly.
- [X] All new and existing tests passed.
- [X] This PR does not contain plagiarized content.
- [X] The title of my pull request is a short description of the requested changes.
Screenshots
Note to reviewers
The proposed changes to the actions which are currently pushing to main
follow the same pattern:
- Instead of pushing to main, push to a uniquely named, new branch, e.g.
release-from-<commit-sha>
. - Create a PR using the
gh
CLI tool which is installed and usable on all managed GitHub runners (see here). - Merge this PR using the
gh
CLI tool and a token which authorizes the action to do the merge. In the current draft, a merge commit is used and the merge gets forced, i.e. pending/failed actions are ignored via the--admin
flag. - Continue with the remaining, existing steps, as all changes are now once again in
main
. - Be happy about green squares and a neat collaboration experience. 🥳
@eddiejaoude @loftwah what do you think about this proposed strategy?
I think since the release action will be modifying the changelog file on main it might have issues as well. The action currently used to create the release is unmaintained, so it could present a problem. See issue #2243
I worked it out, I think. I commented all involved steps for better documentation of what is actually happening, see also this action log as proof of concept:
https://github.com/mocdaniel/action-test/actions/runs/3862144796/jobs/6583557437
Btw your test 2 PR has conflicts, is that for another reason?
Btw your test 2 PR has conflicts, is that for another reason?
Yes, that's because several 'release branches' exist(ed) at the same time due to the action not working at that point of time. Now that everything works, there will never be competing 'release branches', so this shouldn't be a problem, really.
This combination of workflows does its job now, but for some reason I couldn't figure out it created empty changelogs for me. We might have to test this a bit more, or maybe one of you knows why this is happening.