* lisp/vc/diff-mode.el (diff-setup-buffer-type): Remove "\n" from regexp.
Remove extra "\n" from the end of the "diff --git.*" part of 'diff-outline-regexp' because "\n" is not used in outline-regexp and causes problems in such cases like when killing hunks in the diff buffer with outline-minor-mode that loses the outline icons because outline--fix-buttons-after-change and outline--fix-up-all-buttons are limited to the single line and can't match an outline line with a regexp that ends with "\n".
This commit is contained in:
parent
c2bb763580
commit
f54b1d9f7b
1 changed files with 1 additions and 1 deletions
|
@ -1619,7 +1619,7 @@ modified lines of the diff."
|
|||
nil)))
|
||||
(when (eq diff-buffer-type 'git)
|
||||
(setq diff-outline-regexp
|
||||
(concat "\\(^diff --git.*\n\\|" diff-hunk-header-re "\\)")))
|
||||
(concat "\\(^diff --git.*\\|" diff-hunk-header-re "\\)")))
|
||||
(setq-local outline-level #'diff--outline-level)
|
||||
(setq-local outline-regexp diff-outline-regexp))
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue