Can't update preferences and can't get rid of Welcome dialog in Gnucash 2.4.7 (OS X 2.6.8)
prl
prl at ozemail.com.au
Mon Aug 8 18:45:36 EDT 2011
On 9/08/11 4:48, John Ralls wrote:
> It seems that both "$*" and "$@" work, at least on Snow Leopard. I think, though, that "$@" is a bit safer, so I'll put that into the next release. Thanks.
>
> Regards,
> John Ralls
>
Hi, John. In this context, "$@" is IMO the correct subtitution (and not
just "a bit safer").
"$*" expands as "$1 $2 $3 $4 ..."
"$@" expands as "$1" "$2" "$3" "$4" ...
So, for example, if you ran:
/Applications/.../Gnucash --extra --logto="/path/that has/spaces"
The --debug comes from $EXTRA_ARGS.
If you use "$@" then the final effect of the script would be:
exec /Applications/.../Gnucash-bin --debug "--extra"
"--logto=/path/that has/spaces"
which is correct.
However, if you use "$*", then the final effect is:
exec /Applications/.../Gnucash-bin --debug "--extra
--logto=/path/that has/spaces"
which is really not what you want.
I think that what you've tested may not adequately test the difference
between "$*" and "$@". They have the same effect if at the time that
they are expanded, there is only one command-line argument. They only
behave differently if, when they are expanded, there are two or more
command line arguments, as in the example I've given above.
Regards,
Peter
More information about the gnucash-user
mailing list