help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to really clear eshell buffer?


From: Bob Newell
Subject: Re: How to really clear eshell buffer?
Date: Fri, 8 Jun 2018 07:50:39 -1000

> I want to really clear an eshell buffer, which means that all former output 
> is deleted, not just scrolled away.

(defun clear-eshell ()
(interactive)
(setq inhibit-read-only t)
(kill-region (point-min) (point-max)))

I don't see any real need to switch back to read-only mode.

Tie to a key if you wish and run while in the eshell buffer.





-- 
Bob Newell
Honolulu, Hawai`i

Sent via Linux Mint 17.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]