GIT – USEFUL COMMANDS


In some cases, you will need to face issues on your code. Those are mostly the bests moments to exploit the functionalities of our version control system.

Below, i’m going to post many useful commands that would help you.

If you made a commit BUT NOT PUSHED IT, and you need to go back for any reason, you can do the following:

If you made a commit AND PUSHED IT, and you need to go back for any reason, you can do the following:

If you made a commit, and you need to remove a file from there, you can do the following: