modulitos
modulitos

Reputation: 15864

Emacs: How to use shell command prompt with emacs?

I am trying to use the shell command to facilitate commands like adding directories, etc. while in emacs. I am having problems getting it to work.

I enter M-! and then my minibuffer says Shell command: but none of my commands are accepted. For example, entering pwd or ls I get messages like pwd is not recognized as an internal or external command, operable program, or batch file.. Any suggestions?

I used this reference, but it does not seem to help with my situation:

http://www.nongnu.org/emacsdoc-fr/manuel/shell.html

Extra Info I am using Windows 7 OS. I also have cygwin64 installed, if that matters. Is emacs just connecting to an external shell, or is the shell built into emacs? If the shell is external, can I connect to cygwin64 (although it may not be worth the trouble).

Any suggestions on how to configure this properly? I found the following resource, but I am not sure whether this is the right direction: http://www.emacswiki.org/emacs/EmacsApp

Upvotes: 4

Views: 1442

Answers (1)

Drew
Drew

Reputation: 30718

Sounds like you need to make sure that variable exec-path includes the directories where those commands (ls etc.) are located.

That error message does not appear to be an Emacs error message (from the Emacs Lisp or C source code), but rather it seems to come from the shell that tries to execute your command.

Upvotes: 2

Related Questions