[SunHELP] source'ing and $1


Mon May 5 14:14:59 CDT 2003


i want to process $1 within a source'd file and then after processing I want
to set $1 to "".  Otherwise
when I re'source  the same ~command~ file, it will use the last shell value
for $1 even when I dont
specify a value on the command line when calling the source program.

example:
. testprog 1
next time ran
. testprog
$1 would contain "1"
so I need $1 to be set to "" at the end of the command file before the next
source run.

I tried shift but that gives 'bad number' when you run out of parameters.

TIA



More information about the SunHELP mailing list