[Git]: Pulling Commit from Other Repository

git

03/21/2020


BASH
# Adding other repository as a remote
git remote add other <GitHub_Path>
# Retrieve commits from other repo
git remote update
# Check commits of other repo & current repo
git log --all --oneline --10 # i.e. shoing 10 logs
# Cherry pick commits
git cherry-pick 1a2b3cd # Put more commit SHA if needed
# Confirm local repository
git log
# Push
git push origin master
# Delete other repo form remote
git remote remove other
# View remote repositories
git remote

WRITTEN BY

Keeping a record