a bash scripting question

Joseph C. Lininger jbahm at pcdesk.net
Thu Aug 7 04:50:36 EDT 2003


Hello,
Any arguments provided on the command line are available via $1 $2 etc. Better put it in quotes when you access it though, just incase the argument is a quoted string with spaces.

-- 
Joseph C. Lininger
jbahm at pcdesk.net

On Wed, 6 Aug 2003, Gregory Nowak wrote:

> Hi all.
>
> Can someone please tell me how to write a bash script that would accept 2
> arguments from the command line, where the first argument would be an
> integer like 1234567, and the second argument would be a text string?
> I would then like to be able to access the variables inside the script
> via $VAR1 and $VAR2.
>
> Thanks for any help.
>
> Greg
>
>
>




More information about the Speakup mailing list