Set parent env with csh script

Dan "yes that is my real name" Smith daniel at island.uu.net
Tue Jan 10 04:49:31 AEST 1989


In article <174 at v7fs1.UUCP> mvp at v7fs1.UUCP (Mike Van Pelt) writes:
>I would like to write a shell script (csh preferred) that will
>set a few environment variables to various things.  Of course,
>just doing   setenv foo bar  in the script only works for that
>subshell and its children, not for the calling shell.

	Source the script instead of running it.  That way, any environment
variables (and csh variables) that the script changes will be seen
in the shell you "sourced" from.

				dan
-- 
    /na/usa/ca/marin/SanRafael/94903/4000CivicCtrDr/IslandGraphics/DanSmith
 daniel at island.uu.net  unicom!daniel at pacbell.com  {lll-crg,apple}!well!dansmith
 ph: +1 415 332 FAST(h) 491 1000(w) 491 0402(Fax)  d: Island's coffee is laced
    my mind likes unix, my hands guitar, my stomach pizza, and my feet skis



More information about the Comp.unix.wizards mailing list