[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to run DOS shell & Cygwin at the same time?
From: |
Galen Boyer |
Subject: |
Re: How to run DOS shell & Cygwin at the same time? |
Date: |
29 Apr 2003 20:35:11 -0500 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.1 |
On Tue, 29 Apr 2003, szhu@SonicWALL.com wrote:
> Hi, I'm using emacs on the windows platform, I'd like to use both
> the bash shell (cygwin), and the DOS shell (because most of my
> colleagues use the .bat scripts). I know how to set "M-x shell"
> to either one of them, how can I add a function to invoke the
> other one?
I use these two functions to change between the two.
(defun set-shell-bash()
(interactive)
;; (setq binary-process-input t)
(setq shell-file-name "bash")
(setq shell-command-switch "-c")
(setq explicit-shell-file-name "bash")
(setenv "SHELL" explicit-shell-file-name)
(setq explicit-sh-args '("-login" "-i"))
(setq w32-quote-process-args ?\")
(setq mswindows-quote-process-args t)
)
(defun set-shell-cmdproxy()
(interactive)
(setq shell-file-name "cmdproxy")
(setq explicit-shell-file-name "cmdproxy")
(setenv "SHELL" explicit-shell-file-name)
(setq explicit-sh-args nil)
(setq w32-quote-process-args nil)
)
What you might do is something like:
M-x set-shell-bash
M-x shell
M-x rename-buffer "*BASH*"
M-x set-shell-cmdproxy
M-x shell
M-x rename-buffer "*CMD*"
--
Galen deForest Boyer
Sweet dreams and flying machines in pieces on the ground.