csh setenv with `cat ...`

paul at falstad paul at falstad
Fri Apr 26 14:06:46 AEST 1991


mostek at motcid.UUCP (Frank B. Mostek) wrote:
>I am having a problem with the csh setenv command:
>
>$setenv EXINIT `cat ~/.myexrc`
>`cat ~/.myexrc`: Ambiguous.

The problem is that `cat ~/.myexrc` produces more than one word.  setenv
takes only two arguments.  Do:

setenv EXINIT "`cat ~/.myexrc`"

The double quotes prevent the `...` from being split into words.

--
              Paul Falstad  pfalstad at phoenix.princeton.edu
         And on the roads, too, vicious gangs of KEEP LEFT signs!
     If Princeton knew my opinions, they'd have expelled me long ago.



More information about the Comp.unix.shell mailing list