This document shows how to fork a GitHub repo and work from your fork to create clean branches and pull requests. The key is to make sure you stay in sync with the upstream fork's master branch.
First, fork the repo by clicking the Fork button on GitHub. For example, you could fork the tidyverse/ggplot2 repo at https://github.com/tidyverse/ggplot2.