GIT Quick Cmd Tutorial

Some basic GIT Commands:

  • git add .
  • git add . -A
  • git commit -m “comment”
  • git commit -m “fixed #123”
  • git push 
  • git push -u origin master

Create and push a Tag:

  • git tag -a v2.1 -m “Program Version 2.1”
  • git push – -tags

Force Git to overwrite local changes:

  • git fetch – -all

Downloads the latest without trying to merge or rebase anything.

  • git reset – -hard origin/master

Force Git to reset the local state to the downloaded one. If some local changes differ from the downloaded version they are overwritten! 

  • git log

Leave a Reply

Your email address will not be published. Required fields are marked *