Re: [PATCH v2 1/2] t: don't spuriously close and reopen quotes

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

 



On Thu, Aug 6, 2020 at 4:09 PM Martin Ågren <martin.agren@xxxxxxxxx> wrote:
> diff --git a/t/t4200-rerere.sh b/t/t4200-rerere.sh
> @@ -364,7 +364,7 @@ test_expect_success 'set up an unresolved merge' '
>         fifth=$(git rev-parse fifth) &&
> -       echo "$fifth            branch 'fifth' of ." |
> +       echo "$fifth            branch fifth of ." |
>         git fmt-merge-msg >msg &&

This one is a bit weird. It really seems as if the intent was to quote
the word "fifth" in the merge message, so dropping the quotes
altogether seems wrong. However, the file 'msg' is never even
consulted in this test (or any other test), so is this just "dead
code" (including the leading 'fifth=' assignment which also is
otherwise unused outside the 'echo')?

> diff --git a/t/t5510-fetch.sh b/t/t5510-fetch.sh
> @@ -213,7 +213,7 @@ test_expect_success 'fetch tags when there is no tags' '
>  test_expect_success 'fetch following tags' '
>         cd "$D" &&
> -       git tag -a -m 'annotated' anno HEAD &&
> +       git tag -a -m "annotated" anno HEAD &&

There are a fair number of these quoted single-token arguments
containing no special characters which don't actually need to be
quoted at all, so an alternative would be simply to drop the quotes
altogether, making the commands less syntactically noisy. However,
that might be outside the intended scope of this change.



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux