Let's say I am working on my master in my own repository. My upstream for example is main-upstream.
But I need one specific commit from another remote - special-upstream. I don't want another changes from it - I do not need all commits from that remote and I don't want any changes from it - it's a different project - except one certain commit with certain hash from branch master.
Is it possible to cherry-pick it?
Add the other repo as a remote and fetch it's commits:
git remote add otherremote <url to other remote>
git fetch otherremote
Cherry pick the commit from the other repo
git cherry-pick <sha1 from otherremote>
This will cherry-pick the selected commit into the current branch.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With