madots: function to kill buffers

This commit is contained in:
MitchMarq42 2023-01-12 19:34:48 -09:00
parent b276cb7c9b
commit d283e0064e

View File

@ -854,6 +854,11 @@ Return nil if DIR is not in a hugo project at all."
(if (string-match-p "magit: " (buffer-name buffer))
buffer))
(buffer-list))))))
(defun madots--kill-all-magit-buffers ()
(mapcar (lambda (buffer)
(if (string-match-p "^magit" (buffer-name buffer))
(kill-buffer buffer)))
(buffer-list)))
(defun madots--cleanup ()
"Remove modifications made for `madots' once all magit buffers are killed."
(if (not (madots--magit-buffers-p))