david@wubios.wustl.edu (David J. Camp) (01/30/89)
I have been trying to invoke an editor from elm via a script. It seems to work if it is a sh script, but not a csh script. I do not understand sh as well as I do csh, and it seems less capable, so it would be nice if this situation could be rectified. -David- -- Bitnet: david@wubios.wustl ^ Mr. David J. Camp Internet: david%wubios@wucs1.wustl.edu < * > Box 8067, Biostatistics uucp: uunet!wucs1!wubios!david v 660 South Euclid Washington University Medical School Saint Louis, MO 63110
rob@pbhyf.PacBell.COM (Rob Bernardo) (01/31/89)
In article <292@wubios.wustl.edu> david@wubios.wustl.edu (David J. Camp) writes:
+I have been trying to invoke an editor from elm via a script. It seems
+to work if it is a sh script, but not a csh script. I do not
+understand sh as well as I do csh, and it seems less capable, so it
+would be nice if this situation could be rectified.
ELM uses the *standard* library function system(3) to invoke the editor
you've specified in your elmrc (or the default editor as configured).
That means that your editor is interpreted as a Bourne shell command line
less the name of the file which to edit. That's why your csh script doesn't
work.
You should be able to specify your editor as "csh -c [name of csh script]".
--
Rob Bernardo, Pacific Bell UNIX/C Reusable Code Library
Email: ...![backbone]!pacbell!pbhyf!rob OR rob@pbhyf.PacBell.COM
Office: (415) 823-2417 Room 4E750A, San Ramon Valley Administrative Center
Residence: (415) 827-4301 R Bar JB, Concord, California
jonathan@turing.ac.uk (Jonathan Shapiro) (02/03/89)
In article <292@wubios.wustl.edu> david@wubios.wustl.edu (David J. Camp) writes: >I have been trying to invoke an editor from elm via a script. It seems >to work if it is a sh script, but not a csh script. I do not >understand sh as well as I do csh, and it seems less capable, so it >would be nice if this situation could be rectified. >-David- The main reason for applications being written to work with 'sh' is that it is guaranteed to exist on *all* unix machines. There is no such guarantee with 'csh'. --jonathan