In foss, we fork git project from upstream our account and clone to local.
We need to make sure that the respository is up-to-date, so sync to upstream is necessary.
But sometimes when we use
git pull which is combined as
git fetch and
git merge, nonecessary merge occurs.
To avoid redundant merge commit, we use
git pull --rebase instead.
redfish[~] $ git pull --rebase upstream master redfish[~] $ git push origin master <-f>
<-f> : force updated, that’s because you only rebase the local, but origin doesn’t not rebase.