Re: [PATCH v4 1/8] t5504: modernize test by moving heredocs into test bodies

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

 



Eric Sunshine <sunshine@xxxxxxxxxxxxxx> writes:

>> @@ -78,6 +72,11 @@ test_expect_success 'push without strict' '
>> +       cat >exp <<-EOF &&
>> +       To dst
>> +       !       refs/heads/main:refs/heads/test [remote rejected] (missing necessary objects)
>> +       Done
>> +       EOF
>
> It's minor, but to make this conform to modern style even more, it
> would use `\EOF` rather than `EOF`.
>
> (Probably not worth a reroll on its own.)

Yup.  The rule of thumb is to quote the end-of-heredoc marker when
the here-doc does not need interpolation, to serve as a hint to tell
the readers that the here-doc is a literal text.




[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