{"thread":{"id":"48824","subject":"[PATCH] t5500: prettify non-commit tag tests","startedAt":"2018-07-03T16:55:24Z","lastAt":"2018-07-04T06:39:03Z","messageCount":3,"participants":["Jeff King","Taylor Blau","Kirill Smelkov"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"351629","messageId":"20180703165518.GA29295@sigill.intra.peff.net","threadId":"48824","inReplyTo":null,"subject":"[PATCH] t5500: prettify non-commit tag tests","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2018-07-03T16:55:19Z","receivedAt":"2018-07-03T16:55:24Z","isPatch":true,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"We don't need to use backslash continuation, as the \"&&\"\nalready provides continuation (and happily soaks up empty\nlines between commands).\n\nWe can also expand the multi-line printf into a\nhere-document, which lets us use line breaks more naturally\n(and avoids another continuation that required us to break\nthe natural indentation).\n\nSigned-off-by: Jeff King <peff@peff.net>\n---\nI had prepared this as a squash-in for what became c12c9df527, but since\nthat's now in master, it can go on top (or get dropped, but I think it\nis worth it as a style fixup).\n\n t/t5500-fetch-pack.sh | 19 +++++++++++++------\n 1 file changed, 13 insertions(+), 6 deletions(-)\n\ndiff --git a/t/t5500-fetch-pack.sh b/t/t5500-fetch-pack.sh\nindex ea6570e819..3d33ab3875 100755\n--- a/t/t5500-fetch-pack.sh\n+++ b/t/t5500-fetch-pack.sh\n@@ -533,19 +533,26 @@ test_expect_success 'test --all wrt tag to non-commits' '\n \t# are reachable only via created tag references.\n \tblob=$(echo \"hello blob\" | git hash-object -t blob -w --stdin) &&\n \tgit tag -a -m \"tag -> blob\" tag-to-blob $blob &&\n- \\\n+\n \ttree=$(printf \"100644 blob $blob\\tfile\" | git mktree) &&\n \tgit tag -a -m \"tag -> tree\" tag-to-tree $tree &&\n- \\\n+\n \ttree2=$(printf \"100644 blob $blob\\tfile2\" | git mktree) &&\n \tcommit=$(git commit-tree -m \"hello commit\" $tree) &&\n \tgit tag -a -m \"tag -> commit\" tag-to-commit $commit &&\n- \\\n+\n \tblob2=$(echo \"hello blob2\" | git hash-object -t blob -w --stdin) &&\n-\ttag=$(printf \"object $blob2\\ntype blob\\ntag tag-to-blob2\\n\\\n-tagger author A U Thor <author@example.com> 0 +0000\\n\\nhello tag\" | git mktag) &&\n+\ttag=$(git mktag <<-EOF\n+\t\tobject $blob2\n+\t\ttype blob\n+\t\ttag tag-to-blob2\n+\t\ttagger author A U Thor <author@example.com> 0 +0000\n+\n+\t\thello tag\n+\tEOF\n+\t) &&\n \tgit tag -a -m \"tag -> tag\" tag-to-tag $tag &&\n- \\\n+\n \t# `fetch-pack --all` should succeed fetching all those objects.\n \tmkdir fetchall &&\n \t(\n-- \n2.18.0.359.ge51c883f96\n"},{"id":"351635","messageId":"20180703182518.GA89464@syl.attlocal.net","threadId":"48824","inReplyTo":"20180703165518.GA29295@sigill.intra.peff.net","subject":"Re: [PATCH] t5500: prettify non-commit tag tests","fromName":"Taylor Blau","fromEmail":"me@ttaylorr.com","sentAt":"2018-07-03T18:25:18Z","receivedAt":"2018-07-03T18:25:25Z","isPatch":true,"sender":{"key":"me@ttaylorr.com","avatar":"https://avatars.githubusercontent.com/u/301000140?v=4"},"body":"On Tue, Jul 03, 2018 at 12:55:19PM -0400, Jeff King wrote:\n> We don't need to use backslash continuation, as the \"&&\"\n> already provides continuation (and happily soaks up empty\n> lines between commands).\n\nOK. That seems correct according to my recollection.\n\n> We can also expand the multi-line printf into a\n> here-document, which lets us use line breaks more naturally\n> (and avoids another continuation that required us to break\n> the natural indentation).\n\nThe patch below seems obviously correct to me, for what my $.02 is worth\n:-).\n\n> Signed-off-by: Jeff King <peff@peff.net>\n\nThanks,\nTaylor\n"},{"id":"351678","messageId":"20180704062353.GA24862@deco.navytux.spb.ru","threadId":"48824","inReplyTo":"20180703165518.GA29295@sigill.intra.peff.net","subject":"Re: [PATCH] t5500: prettify non-commit tag tests","fromName":"Kirill Smelkov","fromEmail":"kirr@nexedi.com","sentAt":"2018-07-04T06:23:59Z","receivedAt":"2018-07-04T06:39:03Z","isPatch":true,"sender":{"key":"kirr@nexedi.com","avatar":"https://avatars.githubusercontent.com/u/1794248?v=4"},"body":"On Tue, Jul 03, 2018 at 12:55:19PM -0400, Jeff King wrote:\n> I had prepared this as a squash-in for what became c12c9df527, but since\n> that's now in master, it can go on top (or get dropped, but I think it\n> is worth it as a style fixup).\n\nI'm ok with the patch. I thought it was already squashed in into my\nversion, but maybe it got lost.\n\nThanks for this prettification.\n\nKirill\n"}]}