Re: [PATCH 0/2] t: add and use a commit_body test helper
Shlok Kulshreshtha <[email protected]>
| Newsgroups | org.kernel.vger.git |
|---|---|
| Message-ID | <[email protected]> |
Junio C Hamano <[email protected]> writes: > Doesn't 'message_body' t7509 has follow the same pattern to hide > exit code from 'git cat-file commit'? Yes, you are right, I had missed that one. t7509 defines its own local message_body() helper: message_body () { git cat-file commit "$1" | sed -e '1,/^$/d' } which pipes "git cat-file commit" into "sed", the same exit-code-hiding idiom commit_body was introduced to replace. While rechecking, I found one more site with the same problem in t3404-rebase-interactive.sh, a spacing variant of the idiom ("sed -e 1,/^\$/d" without quotes around the address) that didn't match the four spellings I had searched for in the original patch. I've replaced both -- the message_body helper (and its call sites) in t7509, and the inline pipe in t3404 -- with commit_body. Will send a v2 with these folded in. Thanks.