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

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

Re: Open multiple separate terminal buffers with multi-term in Emacs.


From: Joost Kremers
Subject: Re: Open multiple separate terminal buffers with multi-term in Emacs.
Date: Wed, 02 Jun 2021 12:04:29 +0200
User-agent: mu4e 1.5.12; emacs 27.2

On Wed, Jun 02 2021, Hongyi Zhao wrote:
> Based on the author said on GitHub,
> <https://github.com/manateelazycat/multi-term>:
>
> I mainly use Aweshell now, but I still maintain multi-term.el, feel
> free send PR to me, thank you!
>
> So, perhaps I should also give aweshell
> (https://github.com/manateelazycat/aweshell) a try.

That depends. From the looks of it, aweshell is to eshell what multi-term is to
term. The thing is, you have several choices when it comes to running a shell
inside Emacs. There is `M-x shell`, `M-x term` and `M-x eshell`. shell and term
both run a system shell (bash or zsh or whatever you like) as a subprocess and
display the output in a buffer. They have some differences in the way they
interact with Emacs. Details are described in the manual:

https://www.gnu.org/software/emacs/manual/html_node/emacs/Shell.html

Or in Emacs itself: `C-h i emacs RET shell RET`.

Eshell is a shell implementation written in Elisp. That's to say, it's the Elisp
equivalent of bash, zsh, etc. It doesn't run a shell subprocess and everything
it does is done through Emacs (unlike term and shell, which basically just pass
every character you type to the subprocess).

Eshell generally integrates better with Emacs (e.g., you can use Elisp commands
in the shell), but it behaves differently from bash or zsh, so not everything
you know about the shell you normally use carries over.

Which method to use depends on personal preference, the tasks you normally do on
the shell and probably on other factors as well. M-x term is perhaps the easiest
to start with, because everything basically works in the same way as when
running a shell in a terminal emulator such as xterm, rxvt, Terminal, etc. You
just need to know about line mode and char mode, and how to switch between them.
With M-x shell, you don't need to bother with that, but certain things won't
work. (For example, try running `htop` in both.) Eshell is the most emacs-y of
the three. Its integration with Emacs is great and it's a good shell too, but
its command syntax is different once you get to more powerful stuff such as for
loops.

-- 
Joost Kremers
Life has its moments



reply via email to

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