Re: [PATCH 4/4] rebase -i: Add tests for "--edit-todo"
- From
Andrew Wong <andrew.kw.w@gmail.com>
- Date
- Sep 18, 2012, 05:23 UTC
- Message-ID
- <5058053C.6080206@gmail.com>
- In-Reply-To
- <CANiSa6jcBWbeydMViruM1UYanhHiEugfHa5DepjGNdizq2otbA@mail.gmail.com>
On 09/18/12 00:58, Martin von Zweigbergk wrote:
Show 5 quoted lines
> On Mon, Sep 17, 2012 at 6:28 PM, Andrew Wong <andrew.kw.w@gmail.com> wrote: >> + test M = $(git cat-file commit HEAD^ | sed -ne \$p) && >> + test L = $(git cat-file commit HEAD | sed -ne \$p) > I couldn't find "$" (match last line) in the POSIX man page for sed. > Besides, I think $(git show -s --format=%s HEAD) reads better.
It's under "Addresses in sed":
... a '$' character that addresses the last line of input ...
from:
http://pubs.opengroup.org/onlinepubs/009695399/utilities/sed.htmlVarious places in that test get the content of files that way, so I thought it's better to just follow the rest of the test. I agree that there are better ways to achieve the same thing though.