Usually, the workflow looks like this on github:
- You find a repo you want to contribute to, say coala/coala
- You fork it on github, which creates a copy zenara/coala
- You copy it to your machine with git clone https://github.com/zenara/coala (actually, it's better to use ssh here, but let's omit that now) At this point, git creates origin that points to your repo: zenara/coala.
- You create upstream with git remote add upstream https://github.com/coala/coala that points back to original repo.
- You create a local branch with your changes: git checkout -b zenara-awesome-feature
- You develop/test it for a long-long time (the coala/coala repo moves forward in the meantime)
- You are ready with your local feature branch. Now, you need to catch up with the coala/coala repo.
- You get back to the local master branch (which is "old" now): git checkout master