A basic workflow to create a new branch, do work on it:
$ git pull
$ git checkout -b <branchname>
... code edits ...
$ git [add|rm] <files>
$ git commit -m '<commit message>'
To get the latest changes from origin into your branch:
$ git fetch
$ git rebase origin/master
To push your local branch to origin:
$ git push origin <branchname>
To merge the branch into master:
$ git checkout <branchname>
$ git pull
$ git checkout master
$ git pull
$ git merge <branchname>
$ git push
To get bash completion of branch names install git-completion (instructions at the top):
If you would like automatic rebasing everywhere run:
$ git config branch.autosetuprebase always
$ git config branch.master.rebase true