Skip to content

Instantly share code, notes, and snippets.

@originalhat
Created September 7, 2012 15:27
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save originalhat/3667167 to your computer and use it in GitHub Desktop.
Save originalhat/3667167 to your computer and use it in GitHub Desktop.
basic git commands for adding

see the status of shit

$ git status
# On branch develop
nothing to commit (working directory clean)

see branches

$ git branch
* develop
  master

$ git branch -all
* develop
  master
  remotes/origin/HEAD -> origin/master
  remotes/origin/develop
  remotes/origin/master

see changes (shows changes since last commit)

$ git diff

adding

add all files

$ git add . 

add specific files

$ git add uber-file

committing

$ git commit -m "i did something"

combine add and commit

$ git commit -am "i did something"

getting updates from repo

$ git pull origin develop

where develop is whatever branch you want to pull from.

@SiMoG97
Copy link

SiMoG97 commented Jul 6, 2019

???????????????

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment