git-notes

common issues:
1. un-reverting
    mylaptop MINGW64 /c/devspace/myproject (master|REVERTING)
    solution:
    $  git reset --hard HEAD



common commands:
1. delete stash:
    A stash created with @code{git stash} or @code{git stash save}
    so can be deleted with 
        git stash drop
    or 
        git stash drop stash@{n}, where n is the number shown by git stash list.

2. revert commit and force push, this will even delete the git history.
  git reset --hard the-commit-number-you-want-to-back
  git push -f

猜你喜欢

转载自www.cnblogs.com/huanlegu0426/p/git-notes.html