aboutsummaryrefslogtreecommitdiffstats
path: root/emacs
diff options
context:
space:
mode:
authorGravatar Tom Willemse2016-11-04 12:36:41 +0100
committerGravatar Tom Willemse2016-11-04 12:36:41 +0100
commit1031d0478af054660b4d6c66035f9c71d6682fc2 (patch)
tree6fc09f200fcbdca9bac27bdd18e3613243f02a3d /emacs
parent2eb9704befff9049be6fce1bd4035bd138115eba (diff)
downloadnew-dotfiles-1031d0478af054660b4d6c66035f9c71d6682fc2.tar.gz
new-dotfiles-1031d0478af054660b4d6c66035f9c71d6682fc2.zip
Fix eshell configuration
Diffstat (limited to 'emacs')
-rw-r--r--emacs/.emacs.d/init/oni-eshell-init.org11
1 files changed, 9 insertions, 2 deletions
diff --git a/emacs/.emacs.d/init/oni-eshell-init.org b/emacs/.emacs.d/init/oni-eshell-init.org
index 185043c..95dddc2 100644
--- a/emacs/.emacs.d/init/oni-eshell-init.org
+++ b/emacs/.emacs.d/init/oni-eshell-init.org
@@ -5,8 +5,15 @@
#+END_SRC
Truncate the eshell buffer when it gets larger than
-=eshell-buffer-maximum-lines= number of lines.
+=eshell-buffer-maximum-lines= number of lines. For some reason I have
+to use the =eshell-load-hook= instead of just relying on ~eshell.el~
+and ~esh-mode.el~ being loaded because it seems that
+=with-eval-after-load= loads this file before ~eshell.el~ is actually
+loaded.
#+BEGIN_SRC emacs-lisp
- (add-to-list 'eshell-output-filter-functions 'eshell-truncate-buffer)
+ (defun oni:enable-truncating-eshell-buffers ()
+ (add-to-list 'eshell-output-filter-functions 'eshell-truncate-buffer))
+
+ (add-hook 'eshell-load-hook #'oni:enable-truncating-eshell-buffers)
#+END_SRC