I have been doing this way of getting latest code from Git for years now and I wanted to ask if this is really the correct way of doing it since in this way, I prevent merge conflicts when opening a pull request later on.
P-Parent branch (where other devs create their pull request)
W-working branch (branched from P)
- stash changes in W
- Checkout P
- Pull P to get latest commits from remote
- Checkout W
- Merge P to W
- Push incoming commits to W remote
- Pop stash and continue working
- Stage changes once done then Commit
- Push to remote W
- Send pull request to P and once approved, merge
Is there anyone here doing the same thing or are there other ways of doing it?