Cleanly unstage file deletions.
* magit.el (magit-unstage-item): Use "-q" to shut up git reset when unstaging a deletion. Otherwise it would complain about local changes.
This commit is contained in:
parent
0721a4c951
commit
6b839c8df0
1 changed files with 1 additions and 1 deletions
2
magit.el
2
magit.el
|
@ -1161,7 +1161,7 @@ Please see the manual for a complete description of Magit.
|
||||||
((staged diff hunk)
|
((staged diff hunk)
|
||||||
(magit-apply-hunk-item item "--cached" "--reverse"))
|
(magit-apply-hunk-item item "--cached" "--reverse"))
|
||||||
((staged diff)
|
((staged diff)
|
||||||
(magit-run "git" "reset" "HEAD" (magit-diff-item-file item)))
|
(magit-run "git" "reset" "-q" "HEAD" "--" (magit-diff-item-file item)))
|
||||||
((unstaged *)
|
((unstaged *)
|
||||||
(error "Already unstaged"))
|
(error "Already unstaged"))
|
||||||
((hunk)
|
((hunk)
|
||||||
|
|
Loading…
Reference in a new issue