diff options
author | Alan Pearce | 2019-09-27 16:25:11 +0200 |
---|---|---|
committer | Alan Pearce | 2019-09-27 16:25:11 +0200 |
commit | e6e57579b02658d171295b9224532309c06a2320 (patch) | |
tree | 7356ae95d4594feb0f4bbf230a14893267b9aca1 /emacs | |
parent | 48dffdc2664f86f486a2c94c1051202af97e2f15 (diff) | |
download | dotfiles-e6e57579b02658d171295b9224532309c06a2320.tar.lz dotfiles-e6e57579b02658d171295b9224532309c06a2320.tar.zst dotfiles-e6e57579b02658d171295b9224532309c06a2320.zip |
Emacs: parse ANSI colour codes in compilation (e.g. tsc) buffers
Diffstat (limited to 'emacs')
-rw-r--r-- | emacs/.emacs.d/main.el | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/emacs/.emacs.d/main.el b/emacs/.emacs.d/main.el index c7960ca..88d0d55 100644 --- a/emacs/.emacs.d/main.el +++ b/emacs/.emacs.d/main.el @@ -610,6 +610,10 @@ _p_rev _u_pper _=_: upper/lower _r_esolve ;;;; typescript (custom-set-variables '(typescript-indent-level 2)) +(autoload 'ansi-color-apply-on-region "ansi-color") +(defun colorise-compilation-buffer () + (ansi-color-apply-on-region compilation-filter-start (point-max))) +(add-hook 'compilation-filter-hook #'colorise-compilation-buffer) ;;;; shell (general-add-hook 'sh-mode-hook |