Mastering Eshell

Mickey has (re)posted his article on Eshell. I think he’s updated it a bit because he talks about Emacs 28 but regardless, it’s a great article and every Emacser should read it. The problem with Eshell is that there’s not much documentation so Mickey’s article is especially useful.

There’s too much information packed into the article to give a reasonable précis here but there are a couple of capabilities—one of which I use, and the other that I keep promising myself that I’ll learn and use—that are worth calling out. The first is the ability to cd to a directory on a remote machine when you’re in Eshell. It almost seems like magic and works completely transparently except, of course, that you have use the standard Tramp notation for describing a remote file/directory.

The second really great feature is that Eshell implements zsh’s argument predicates. The later Apple OSs now use zsh by default so there’s even less excuse for me not to become adept at their use. The idea is easy, it’s just a matter of learning what the modifiers and predicates are. Fortunately, there are a couple of Emacs commands, eshell-display-predicate-help and eshell-display-modifier-help that pops up a window with lists of the predicates and modifiers. The commands put focus in the window so it’s easy to quit out of it with q. This is especially handy for me because I run Eshell as a full-frame window. As Mickey says, if you use argument predicates a lot it’s probably worthwhile adding an alias for these commands.

There is much more information in the article so be sure to take a look.

This entry was posted in General and tagged . Bookmark the permalink.