Skip to content

Commit

Permalink
add elisp functions that clean up compilation output
Browse files Browse the repository at this point in the history
  • Loading branch information
lecopivo committed Jun 19, 2024
1 parent a81c2c9 commit c746548
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .dir-locals.el
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,20 @@
((lean4-mode . ((fill-column . 100)
(show-trailing-whitespace . t)
(eval . (add-hook 'before-save-hook 'delete-trailing-whitespace nil t)))))



;; hide warning/note/info from compilation output
;; ((nil . ((eval . (progn
;; (require 'compile)
;; (defun my-hide-compilation-warnings ()
;; "Hide lines in compilation buffer that start with 'warning:', 'note:', or 'info:'."
;; (save-excursion
;; (goto-char (point-min))
;; (while (re-search-forward "^\\(warning\\|note\\|info\\):.*\n" nil t)
;; (replace-match ""))))
;; (defun my-add-compilation-hook ()
;; "Add compilation filter hook if buffer is visiting a file."
;; (when buffer-file-name
;; (add-hook 'compilation-filter-hook 'my-hide-compilation-warnings)))
;; (add-hook 'find-file-hook 'my-add-compilation-hook))))))

0 comments on commit c746548

Please sign in to comment.