Abort when looking at stashed changes

* lisp/vc/vc-git.el (vc-git-find-file-hook): Abort when looking at
stashed changes (bug#20292).
This commit is contained in:
Dmitry Gutov 2015-04-19 19:28:17 +03:00
parent 96bfe816d8
commit d35f2f4822

View file

@ -800,7 +800,9 @@ This prompts for a branch to merge from."
(vc-git-conflicted-files buffer-file-name)
(save-excursion
(goto-char (point-min))
(re-search-forward "^<<<<<<< " nil 'noerror)))
(and (re-search-forward "^>>>>>>> " nil 'noerror)
;; Stashes are tricky (bug#20292).
(not (looking-at "Stashed changes")))))
(vc-file-setprop buffer-file-name 'vc-state 'conflict)
(smerge-start-session)
(add-hook 'after-save-hook 'vc-git-resolve-when-done nil 'local)