[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: passing array to command line argument.
From: |
Andreas Schwab |
Subject: |
Re: passing array to command line argument. |
Date: |
Fri, 12 Dec 2008 09:43:11 +0100 |
User-agent: |
Gnus/5.110009 (No Gnus v0.9) Emacs/22.3 (gnu/linux) |
Chet Ramey <chet.ramey@case.edu> writes:
> Dolphin06 wrote:
>> I dont get it right, i always display only the first one, and i dont know how
>> to write a scalar variable.
>> I tried like this :
>> ssh $USER@$SERVER script2 -f "${my_array[@]}"
>
> Stick an `echo' in front of this command and see what you're executing.
Better yet: set -x to get an accurate view of the command, including
quoting.
Andreas.
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."