Questions tagged [shell]

Questions relating to commands for passing single command lines to shell sub-processes, running a shell interactively with input and output to an Emacs buffer, and for running a shell in a terminal emulator window.

362 questions
41
votes
4 answers

Weird shell output when using IPython 5

I just upgraded to the latest version of IPython and now something is wrong when using it in emacs. When using it in a regular terminal it works fine (colors, tab-completion, etc.), however either in M-x eshell or M-x shell, instead of outputing In…
Literal
  • 675
  • 5
  • 10
28
votes
1 answer

What are all the ways of launching a shell from inside emacs and what are their various properties?

I know of at least four possibilities: eshell term ansi-term shell What's the complete list of tools built-in to emacs to launch a shell, and what benefits and drawbacks do they offer?
Trevoke
  • 2,375
  • 21
  • 34
25
votes
4 answers

How can I run an async process in the background without popping up a buffer?

I have defined some functions to run async background process using async-shell-command in my .emacs, but everytime I run the commands a new window (not frame) is created and the process' buffer is shown there. How could I run the command without…
rlazo
  • 983
  • 8
  • 13
25
votes
7 answers

Emacs and command line $PATH disagreements on OSX

Having some issues with PATH settings on Emacs that are affecting my Haskell environment: I'm using ZSH, and when I go to the command line and call echo $PATH, it returns:…
Galder Zamarreño
  • 1,527
  • 2
  • 12
  • 21
24
votes
2 answers

Tramp mode is much slower than using terminal to ssh

I am using the Macports flavor of Emacs on OSX Yosemite, and have looked through every thread here on Tramp being slow without any solution. Tramp is usable, but there is about a 100ms delay between every action. It's not a problem on the server's…
m0meni
  • 743
  • 1
  • 6
  • 17
14
votes
3 answers

How i can open shell in current buffer?

In function "shell" this line display shell buffer and almost always its open new shell in random frame. And I have to swap the buffers, it's annoying. ... (pop-to-buffer buffer) ... In docs says: If that window is on a different graphical frame,…
Honnisha
  • 163
  • 1
  • 6
14
votes
3 answers

Git Bash in emacs on Windows

I can run the Bash shell that comes with Git for Windows. I put this in my .emacs: (defun git-bash () (interactive) (let ((explicit-shell-file-name "D:/Program Files/git/bin/bash")) (call-interactively 'shell))) Then M-x git-bash and voila,…
marczellm
  • 245
  • 1
  • 2
  • 8
14
votes
1 answer

How to prevent backspace from deleting my shell prompt?

It is a usual shell display: ME@mycomputer: ~$ echo When I do backspace several times It becomes: ME@mycompu How to prevent the system word from deleting
tom
  • 365
  • 1
  • 7
13
votes
2 answers

.bash_profile or .bashrc for shell in emacs?

I wrote an alias for a huge command and stored it in .bash_profile and to my surprise, emacs didn't pick up the alias that I wrote in .bash_profile. After some searching in the internet, I created a .bashrc file in my $HOME with the alias command…
Chakravarthy Raghunandan
  • 3,132
  • 2
  • 18
  • 42
11
votes
3 answers

how to name buffers (*shell*)

I'm interested in naming Emacs buffers. In particular I'd like to give names to shell buffers that I've started. That way I can easily tell them apart when switching buffers.
m33lky
  • 297
  • 3
  • 9
11
votes
1 answer

Attach to running remote shell with eshell/TRAMP/dtach

I often use GNU Screen to keep remote sessions alive. Since I live in Emacs, I'd really like to be able to resume a running remote shell session from within Emacs. GNU Screen implements all sorts of fancy things like terminal multiplexing and…
user2005
11
votes
1 answer

How to prevent Emacs from showing passphrase in `M-x shell`?

I tried using attic with a passphrase to backup my files from inside M-x shell. The shell exposed the passphrase as plain text in the buffer and made it available by typing M-r as well as by looking through the shell input history with C-c C-l. When…
wdkrnls
  • 3,657
  • 2
  • 27
  • 46
11
votes
1 answer

Is it possible to read user input from STDIN while tangling a source block?

Is it possible to read user input from STDIN while tangling a source block with org-babel-tangle? I am aware of this: Org Mode Babel - Interactive code block evaluation. That doesn't help solve this particular use-case, as it still doesn't allow…
gsl
  • 1,742
  • 17
  • 34
10
votes
1 answer

How do I prevent one subprocess from starving others?

To be clear, I'm not talking about anything that should require emacs to be multithreaded (though that would probably also solve this). To reproduce: emacs -Q # I'm running 24.4.1 Make a second frame Switch back to first frame M-x shell M-x…
Joseph Garvin
  • 2,061
  • 8
  • 21
10
votes
4 answers

How to make shell-command run using shell profile and current directory hooks (ex. direnv)

I am trying to get shell-command and async-shell-command to integrate seamlessly with a couple of programs in my .bashrc file, specifically direnv in this example. I found that if I customized shell-command-switch, I could get shell processes to…
waymondo
  • 1,384
  • 11
  • 16
1
2 3
24 25