git rebase forked repo code example
Example 1: update fork repository
git remote add upstream https://github.com/OriginalOwner/OriginalProject.git
git remote -v
git fetch upstream
git checkout master
git merge upstream/master
git push origin master
Example 2: git rebase fork
git remote add upstream https://github.com/whoever/whatever.git
git fetch upstream
git checkout master
git rebase upstream/master
git push -f origin master
Example 3: rebase my fork branch
git checkout master
git remote add author original_repo_that_you_forked_from
git fetch author
git status
git merge author/master
git checkout your-branch
git rebase master
git push origin your_branch