Starting Your favorite editor from Erlang
Per Bergqvist
per@REDACTED
Thu Jul 31 08:34:27 CEST 2003
Note that under windows you need to either use forward slash
or quote the backward slash.
However I think there is a bug regarding long file names with
spaces. Only if I use the short equivalent it works.
os:cmd("c:\Program
Files\XEmacs\XEmacs-21.4.11\i586-pc-win32\xemacs.exe"). %% NOT OK,
expected
os:cmd("c:\progra~1\XEmacs\XEmacs-21.4.11\i586-pc-win32\xemacs.exe").%
% NOT OK, expected
os:cmd("c:/Program
Files/XEmacs/XEmacs-21.4.11/i586-pc-win32/xemacs.exe"). %% NOT OK BUG
os:cmd("c:\\Program
Files\\XEmacs\\XEmacs-21.4.11\\i586-pc-win32\\xemacs.exe"). %% NOT OK
BUG
os:cmd("c:\\progra~1\\XEmacs\\XEmacs-21.4.11\\i586-pc-win32\\xemacs.ex
e"). %% OK
os:cmd("c:/progra~1/XEmacs/XEmacs-21.4.11/i586-pc-win32/xemacs.exe").
%% OK
/Per
-------------------
> Does anyone know how to start Your favorite editor
> e.g. Vi or Emacs from an Erlang program and then
> getting the text back into erlang?
>
> I have tried os:cmd("the correct path\gvim.exe") on
> windows but no succes.
>
> /Anders Nygren
>
> _____________________________________________________
> Gå före i kön och få din sajt värderad på nolltid med Yahoo! Express
> Se mer på: http://se.docs.yahoo.com/info/express/help/index.html
>
=========================================================
Per Bergqvist
Synapse Systems AB
Phone: +46 709 686 685
Email: per@REDACTED
More information about the erlang-questions
mailing list