git reset使用

git reset使用

reset Reset current HEAD to the specified state:[去掉commit]

 

wanqi@wanqi-System-Product-Name:~/huiye_2.3.5/mydroid$ git reset HEAD^
Unstaged changes after reset:
M packages/apps/Email/AndroidManifest.xml
M packages/apps/Email/res/layout/account_folder_table.xml
M packages/apps/Email/src/com/android/email/activity/AccountFolderList.java
M packages/apps/Email/src/com/android/email/activity/AccountFolderMain.java
M packages/apps/Email/src/com/android/email/activity/Welcome.java
wanqi@wanqi-System-Product-Name:~/huiye_2.3.5/mydroid$ git status
# On branch master
# Your branch is ahead of 'origin/master' by 2 commits.
#
# Changes not staged for commit:
# (use "git add <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: packages/apps/Email/AndroidManifest.xml
# modified: packages/apps/Email/res/layout/account_folder_table.xml
# modified: packages/apps/Email/src/com/android/email/activity/AccountFolderList.java
# modified: packages/apps/Email/src/com/android/email/activity/AccountFolderMain.java
# modified: packages/apps/Email/src/com/android/email/activity/Welcome.java
#

你可能感兴趣的:(reset)