[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] maint: use a wildcard to include all syntax check exceptions
From: |
Jim Meyering |
Subject: |
Re: [PATCH] maint: use a wildcard to include all syntax check exceptions in dist |
Date: |
Mon, 08 Jun 2009 14:24:37 +0200 |
Pádraig Brady wrote:
> Jim Meyering wrote:
>> Pádraig Brady wrote:
>>
>> ...
>>> + test "$$(($(VC_LIST) | sed -n '/^.x-sc_/p'; \
>>> + sed -n "/^$$sce =[ ]*\\\\$$/,/[^\]$$/p" \
>>> + $(srcdir)/Makefile.am \
>>> + | sed "s/^ *//;/^$$sce =/d" \
>>> + | tr -s '\012\\' ' ' | fmt -1 \
>>> + ) | sort | uniq -u)" \
>>> + && { echo "Makefile.am: $$sce mismatch" >&2; exit 1; } \
>>> + || :;
>>
>> Quoting infelicity.
>> Notice how the second sed expression is not quoted at all.
s/is/appears/ ;-)
> Well it wouldn't work if it wasn't quoted. I did test :)
> echo "$(echo "two spaces")" seems to be fine.
> But you're right in that it could be confusing.
Yes, I noticed that it worked, too.
Note that "`... "..." ...`" is not portable
(see Shell Substitutions in "info autoconf").
I'm not sure about "$(... "..." ...)".
>> How about this instead?
>
> Sure I'll use a `make` variable instead.
It's nice to avoid the quadruple backslash, too ;-)
> I'll also change the first '$((' to '$( (' so
> that readers aren't confused with arithmetic expansion.
> I'll also add a comment on this make target.
Thanks.