I am going to assume you know the purpose of Git: it saves your code remotely and has many tools to help lots of people work on the same project in parallel.
Why is git so powerful? It allows you to control your work through short commands. All work is tracked neatly in branches and commits.
Let's go over the vocabulary first:
Like this picture shows, you can easily switch between these two windows to use their best functionalities for a smooth workflow.
Use the command line git commands because they are much more powerful than the GUI buttons of GitHub Desktop and they perform much faster and have fewer problems getting stuck. So, the only thing I recommend using GitHub Desktop for is the diff tool which is amazing. If you keep it open next to your command line window you can just click on the window and it will update to the branch you are on and show you all the commits and file changes.
Hopefully your branches and commits start out mostly looking like this simple one. Most of the time this person probably just worked on the master branch making commits directly there. The small feature branch was probably a short experiment that turned out to work well and was easily merged back into master. The larger feature branch might never have turned out to be something that worked well and can be left on it's own branch. The larger feature branch work can always be gotten later if it does turn out to be useful to someone.
Here I will give some general steps for how to use Git.
Here is my cheat-sheet of the most common and important git commands to learn like the back of your hand:
Basics of commiting your work:
Basics of using branches:
Basics of git time travel:
OK, now let's see some more advanced ones
In this more complicated example you can see the master branch at the bottom with one initial commit (black dot) of file changes. Then a new branch called sprint integration (red) was created to try out some changes to the project. 4 people then branched off of this new branch to try their own changes, most of which made their way back into master before the end of the sprint which is where red merges back into the master branch which has changes from 3 people that sprint. The blue person just took longer to merge their work into the sprint branch so their feature will not make it back into master probably until the end of the next sprint.
What if I made a commit that I don't like any more and I want to remove it?
git reset --soft HEAD~ will remove the last commit and also save your changes by just making them unstaged file changes