Raw Syntax

The stuff programs are made of

Learn Emacs: Term, Ansi Term


When I first started using Multi-Term to run my terminal in emacs, much of the documentation I saw on the EmacsWiki referenced both ansi-term and term. This left me somewhat confused as to which I should be using and what the difference was. I ignored this for some time while I got my Multi-Term setup working correctly.

Look It Up

When the time came to find out the truth, I knew I could just ask emacs. I used C-h a to invoke apropros and fed it both ansi-term and term. The output linked me to term.el and I read the source for both methods. It turns out that both methods work similarly, but simply use different buffer names. As EmacsWiki explains, the difference is largely historical at this point. Previously, plain term-mode was less able to display colors than ansi-term.

This is one of the features I like best about emacs. It has a built-in help system that allowed me to search for term related documentation, and eventually led me to the source code implementation of the method in question. All without leaving the editor!

I have some enhancements to my previous post zsh and multi-term in emacs, and the fixes and changes that I implemented all came from reading the source of term.el and referring to EmacsWiki as needed.