[Top][All Lists]

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

Re: problem with extra space; setting? cygwin only?

From: Chet Ramey
Subject: Re: problem with extra space; setting? cygwin only?
Date: Tue, 23 Jun 2020 16:19:26 -0400
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:68.0) Gecko/20100101 Thunderbird/68.9.0

On 6/23/20 3:21 PM, L A Walsh wrote:
> I do:
> set output
> echo ">$1<"
>> output<
> output=""printf ${1:+-v $1} "%s:%s" 23 myproc
> -Bash: printf: ` output': not a valid identifier

It looks like word splitting on the result of ${1:+-v $1} isn't taking
place. That might be due to IFS; or because this isn't an accurate
representation of your actual script, which includes quoting; or because
the character between the `v' and `$' isn't a space.


``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/

reply via email to

[Prev in Thread] Current Thread [Next in Thread]