[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [h-e-w] Running scripts via call-process...
From: |
Jody Klymak |
Subject: |
Re: [h-e-w] Running scripts via call-process... |
Date: |
Thu, 27 Mar 2003 09:13:23 -0800 |
User-agent: |
Gnus/5.090017 (Oort Gnus v0.17) Emacs/21.2 (windows-nt) |
Hi,
Thanks for your answers...
address@hidden writes:
> Try something like (untested):
> (call-process "c:/cygwin/usr/bin/bash.exe -c /c/jklymak/test.sh")
Unfortunately this, "cmd /c test.sh", and similar invocations give:
(bash is in /bin on my Cygwin).
test: Searching for program: no such file or directory, c:/cygwin/bin/bash.exe
-c c:/jklymak/test.sh
test: Searching for program: no such file or directory, cmd /c
c:/jklymak/test.sh
I tried both bash and cmd as my shells, toggling between:
(defun set-shell-bash ()
"Set the default shell to be bash."
(interactive)
(setq w32-quote-process-args ?\")
(setq shell-file-name "bash")
(setq process-coding-system-alist '(("bash" . undecided-unix)))
(setenv "SHELL" shell-file-name)
(setq explicit-shell-file-name shell-file-name)
(setq explicit-bash-args '("--login" "-i")) ; see shell.el
(setq shell-command-switch "-c")
(add-hook 'comint-output-filter-functions 'comint-strip-ctrl-m)
(message "Shell is now bash")
(setq exec-path (cons "c:/cygwin/bin/" exec-path))
(setq exec-path (cons "c:/cygwin/usr/local/bin/" exec-path))
(setq exec-path (cons "c:/cygwin/usr/bin/" exec-path))
)
(defun set-shell-cmd ()
"Set the default shell to be cmd."
(interactive)
(setq w32-quote-process-args t)
(setq shell-command-switch "/c")
(setq shell-file-name "cmd")
(setq explicit-shell-file-name shell-file-name)
(setenv "SHELL" shell-file-name)
(setq comint-process-echoes t)
(message "Shell is now cmd")
)
Thanks again,
Cheers, Jody
--
Jody Klymak 104 Ocean Admin Bldg., OSU
mailto:address@hidden Corvallis OR, 97330