Example: (use develop as base branch, upstream is original repo, origin is my own fork repo)
Switch local branch
git checkout develop
Get latest changes from upstream:
git pull -r upstream develop
Update own remote fork
git push origin develop
Switch back to working feature branch
git checkout <my_ feature_branch>
Make changes and add to index
git add <files_change>
Commit changes locally
git commit -m “commit message"
Check recent commits
git log
Interactively squash and clean recent commits history
git rebase -i HEAD~2
Force update remote feature branch
git push -f origin <my_ feature_branch>