From: Eric L. <Eri...@ma...> - 2011-12-08 15:06:46
|
Hi, The variable 'matlab-shell-command' needs to be a string that represents a single executable. In your case, you want it to just be "qrsh". You would then set 'matlab-shell-command-switches' to be '("-b" "y" "-q" "single" "-V" ...) with all your switches spelled out. It seems outlook is messing with my 'quote' marks, so you will need to type it in and not copy what I typed here. Good Luck Eric From: David Chappaz [mailto:dav...@fr...] Sent: Thursday, December 08, 2011 7:51 AM To: mat...@li... Subject: [Matlab-emacs-discuss] Matlab-Shell & Sun Grid Engine Hi everyone, I'm having a simple problem configuring matlab-shell-command. The thing is I actually never run matlab locally on the machine I am logged on, but matlab is submitted as a job to a large pool of linux machines with the Sun Grid Engine. In other words, I don't use the "matlab" command at the shell prompt, but instead I use something like: qrsh -b y -q single -V -cwd -noshell matlab Now, everything works fine by default, if I set matlab-shell-command to "matlab". But if I set matlab-shell-command to "qrsh -b y -q single -V -cwd -noshell matlab", a problem occurs in matlab.el (matlab-shell function), and more specifically on this line : (switch-to-buffer (apply 'make-comint matlab-shell-buffer-name matlab-shell-command nil matlab-shell-command-switches)) which returns the error message Searching for program: no such file or directory, qrsh -b y -q single -V -cwd -noshell matlab As a workaround, I have tried defining an alias in my .cshrc, something like: alias sge_matlab 'qrsh -b y -q single -V -cwd -noshell matlab' and this works to manually start matlab from the shell. But again if I set matlab-shell-command to "sge_matlab", then I get apply: Searching for program: no such file or directory, sge_matlab So what is the proper way to get everything to work in my case ? Many thanks in advance ! Cheers, David. |