I decided to go back a few commits because the path I followed was wrong. So I checked out Added cordova to .gitignore
commit, and made some modifications. Like illustrated below :
Now when I push the new modifications, an error message shows up :
error: src refspec (detached from aad6423) does not match any.
How can I tell git to discard the previous commits (in purple) and continue with my local HEAD as master ?