git tips collection (Update)

git tips collection (Update)

Team collaboration, git, svn and other tools are very important in this record only some of the problems encountered in the use of git and solutions, and will be continuously updated.

1, followed by git commit, not push, how to undo?

A: Use the command git reset --soft HEAD ^ can, try not to use the command git the RESET --hard the HEAD , because this withdrawal is very thorough, local file will be deleted (HEAD is pointing to the latest submission, submission is the last time HEAD ^, the last time HEAD ^^, can also be written HEAD ~ 2, and so on)

Guess you like

Origin www.cnblogs.com/cyfblogs/p/11139781.html