[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: multiple words as single variable in bash?



On Wed, Jan 23, 2002 at 10:49:54PM -0100, andrej hocevar wrote:
> Quite self-explanatory -- how to make a string of space-separated 
> words act like a single variable, e.g. first argument being the
> recipient and the second the message or similar? 

Quote them. Use double quotes if you want parameter substitution to
happen inside the quotes, such as "$foo $bar".

-- 
Colin Watson                                  [cjwatson@flatline.org.uk]



Reply to: