Source
Copy the commit hash
For example, I want to take this commit: eccde65
Replica
I’ll use term replica for other repositories that might use the same starter/components.
-
Add the source remote to the replica repository
git remote add source https://github.com/minhub/aether-design-system.git # ^you can name it whatever you like
-
Fetch remote
git fetch source # ^or your remote name git fetch --all # ^if you're feeling lazy (fetch all available repo)
-
Cherry pick
git cherry-pick eccde65
If you have multiple commits to pick from, for example these 3:
put the oldest commit first, the order matters
ex:
git cherry-pick 8cfc164 dee8c34 eccde65
-
Done
it works even if you have other commits that are different from the source
Common Case: Conflict
It’s quite common, don’t panic
For example, you have a commit in the replica that changed PaginatedTable
And you also have a different change on the source’s commit eccde65
It will create a conflict like this
Solve them, add to staging, then continue the cherrypick
git cherry-pick --continue
Demo Video
Here's a demo