emacs: Fix 'guix-build-log-phase-toggle-all'.
* emacs/guix-build-log.el (guix-build-log-phase-toggle-all): Handle the case when there are no characters before the first phase: 'guix-build-log-next-phase' moves to the second phase in such a case, and the toggling is not done properly, so use 're-search-forward' instead.
This commit is contained in:
parent
88908d55e0
commit
7c786db4fb
|
@ -256,8 +256,9 @@ Return nil, if there is no phase start before the current point."
|
||||||
;; Some phases may be hidden, and some shown. Whether to hide or to
|
;; Some phases may be hidden, and some shown. Whether to hide or to
|
||||||
;; show them, it is determined by the state of the first phase here.
|
;; show them, it is determined by the state of the first phase here.
|
||||||
(goto-char (point-min))
|
(goto-char (point-min))
|
||||||
(guix-build-log-next-phase)
|
(let ((fun (save-excursion
|
||||||
(let ((fun (guix-build-log-phase-toggle-function)))
|
(re-search-forward guix-build-log-phase-start-regexp nil t)
|
||||||
|
(guix-build-log-phase-toggle-function))))
|
||||||
(while (re-search-forward guix-build-log-phase-start-regexp nil t)
|
(while (re-search-forward guix-build-log-phase-start-regexp nil t)
|
||||||
(funcall fun)))))
|
(funcall fun)))))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue