aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuchen Pei <id@ypei.org>2023-06-26 16:29:48 +1000
committerYuchen Pei <id@ypei.org>2023-06-26 16:29:48 +1000
commit5164267b0d96ebc4e28616e0ebd2c48c8345dbd5 (patch)
treeb40d2f65de0dee081efae07e9ca0c61893482d74
parenta60e3f385317d4f35d1ab7a853ede6640b4fccc5 (diff)
fixing the post commit project buffer revert hook
-rw-r--r--emacs/.emacs.d/lisp/my/my-project.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/emacs/.emacs.d/lisp/my/my-project.el b/emacs/.emacs.d/lisp/my/my-project.el
index d318e75..677bec6 100644
--- a/emacs/.emacs.d/lisp/my/my-project.el
+++ b/emacs/.emacs.d/lisp/my/my-project.el
@@ -148,7 +148,8 @@ projects."
"Revert all buffers in the current project."
(interactive)
(dolist (buffer (project-buffers (project-current)))
- (revert-buffer-quick buffer)))
+ (when (buffer-file-name)
+ (revert-buffer-quick buffer))))
(provide 'my-project)
;;; my-project.el ends here