Lets try "code owners" https://help.github.com/en/github/creat ... ode-owners feature.
First PR.
https://github.com/freeorion/freeorion/pull/2894
The Git/GitHub Questions, Answers and Howto Thread
Moderator: Committer
Re: The Git/GitHub Questions, Answers and Howto Thread
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0
Re: The Git/GitHub Questions, Answers and Howto Thread
Best way to make PRs that depend on other not-merged PRs?
Say I have PR Feature-1 waiting for approval, and I want to start working on another PR Feature 2 that depends on "Feature 1", and eventually pushing it before Feature-1 was merged. What is the preferred way to make the branching, commits and push to minimise merge conflicts and keep a tidy commit history?
Can I just do?
(edit)
Say I have PR Feature-1 waiting for approval, and I want to start working on another PR Feature 2 that depends on "Feature 1", and eventually pushing it before Feature-1 was merged. What is the preferred way to make the branching, commits and push to minimise merge conflicts and keep a tidy commit history?
Can I just do
Code: Select all
git checkout Feature-1
git checkout -b Feature-2
// hack hack hack
git commit -a -m "This is Feature-2, follow up of Feature-1"
git push origin Feature-2
(edit)
Re: The Git/GitHub Questions, Answers and Howto Thread
Well, yeah. Technically you can. Note, that any PR from Feature-2 to upstream/master will contain also commits from Feature-1. If Feature-1 is merged before Feature-2 it won't be a problem, as the commit is the same (same hash, same parents) and Feature-2 PR will no longer include Feature-1 changes in its commit list (as they will already have been in master). If Feature-2 is merged before Feature-1, Feature-1 PR becomes a no-op, because Feature-2 will have already merged all changes from Feature-1 into master.
https://github.com/macmodrov
[...] for Man has earned his right to hold this planet against all comers, by virtue of occasionally producing someone totally batshit insane. - Randall Munroe, title text to xkcd #556
[...] for Man has earned his right to hold this planet against all comers, by virtue of occasionally producing someone totally batshit insane. - Randall Munroe, title text to xkcd #556
Re: The Git/GitHub Questions, Answers and Howto Thread
Then... Feature-2 PR could indicate that it supersedes Feature-1 when pushed to master (if Feature-1 wasn't merged)?
- Geoff the Medio
- Programming, Design, Admin
- Posts: 12924
- Joined: Wed Oct 08, 2003 1:33 am
- Location: Munich
Re: The Git/GitHub Questions, Answers and Howto Thread
The main problem with those pull requests that include stuff from other pull requests is that it's harder to review the later pull request with the older stuff also in the changes.
Noting in the description that another pull request is included or that the latter one depends on the former is a good practice, though, I think.
Noting in the description that another pull request is included or that the latter one depends on the former is a good practice, though, I think.