45.14 Finding the Last Command-Line Argument
Do you need to pick up the last parameter
except for a small problem with sh argument syntax: $
The only reliable way to get at the last parameter is to use something like for i do last="$i"; done [That for
loop assigns each parameter to the shell variable named
last
;
after the loop ends, - in comp.unix.questions on Usenet, 15 January 1990 |
|