Академический Документы
Профессиональный Документы
Культура Документы
Local
$ git status Show changed 5les in your working directory
$ git add -u Stage modi5ed and deleted 5les, but not untracked 5les
$ git add . Stage new and modi5ed 5les, but not deleted 5les
$ git blame [file] Show changes for ["le] with time and author
http://www.cheetyr.com/git Page 1 of 3
Cheetyr – Git Cheat Sheet 01/06/1938 Saka, 12:10
$ git branch [new branch] Create new branch based on current HEAD
$ git branch --track [new Create new tracking branch based on a remote branch
branch] [remote branch]
$ git tag [tag name] Mark the current commit with a tag
Remote
$ git remote update Refresh list of remotes
$ git fetch [remote] Download all changes from [remote], don't integrate into
HEAD
http://www.cheetyr.com/git Page 2 of 3
Cheetyr – Git Cheat Sheet 01/06/1938 Saka, 12:10
Stash
$ git stash Temporarily store all modi5ed tracked 5les
$ git reset --hard [commit] Reset HEAD to a previous commit and discard all changes
since
$ git reset [commit] Reset HEAD to a previous commit and preserve all changes
as unstaged changes
$ git reset --keep [commit] Reset HEAD to a previous commit and preserve
uncommitted local changes
http://www.cheetyr.com/git Page 3 of 3