Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
restore: default to --source=HEAD when only --staged is specified
"git restore --staged" without --source does not make much sense since by default we restore from the index. Instead of copying the index to itself, set the default source to HEAD in this case, yielding behavior that matches "git reset -- <paths>". Signed-off-by: Nguyễn Thái Ngọc Duy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
- Loading branch information