Confirmed users
1,643
edits
| Line 341: | Line 341: | ||
# soft option: change the referee of the current branch | # soft option: change the referee of the current branch | ||
#* index file and working directory keep untouched. | #* index file and working directory keep untouched. | ||
#* scenario: squash. | #* scenario: squash change in several commits into one commit so that people think you are smart. | ||
# mixed option: soft criteria; regenerate index according to the new tree. | # mixed option: soft criteria; Plus, regenerate index according to the new tree. | ||
#* working directory keeps untouched. | #* working directory keeps untouched. | ||
#* scenario: | #* scenario: slice a single big commit to different small commits to haste review process. | ||
# hard option: mixed criteria; | # hard option: mixed criteria; Plus, overwrite all '''modified''' tracked files in working directory. (Note: only tracked and dirty files will be overwritten by hard-reset. Unchanged and untracked files are out of scope) | ||
#* scenario: | #* scenario: overtime working, did lots of stupid things. You don't want to face what had done... | ||
#* scenario: | #* scenario: recover context before a stale merge | ||
Another usage of reset is to reset paths: | Another usage of reset is to reset paths: | ||