Re: [PATCH v2 0/3] Towards a useable git-branch
- From
Ramkumar Ramachandra <artagnon@gmail.com>
- Date
- May 28, 2013, 14:01 UTC
- Message-ID
- <CALkWK0k=2NZsbSnxS50w+bux8q9mZh7GZzpCqhTP=2jqyHnBSg@mail.gmail.com>
- In-Reply-To
- <CALkWK0kb2D2nH_pDi0TihmFzuEAvWnGJeX0sOXD1TEWLZ7YWHw@mail.gmail.com>
Hi Duy,
I just woke up and started looking at the series: it's rather well done, and I'm confident that this is the way forward. To reciprocate, I've done some work at gh:artagnon/git for-each-ref-pretty. See:
https://github.com/artagnon/git/commits/for-each-ref-pretty
There is one major problem though:
%>(N) doesn't work properly with f-e-r, and I'm not sure why. I'm not talking about your last patch where you compute * -- that works fine; it's just that %>(N) doesn't when N is a concrete number.
Also, a couple of minor annoyances:
1. When f-e-r is invoked with refs/tags, we get stray output. Atleast it doesn't segfault, thanks to your ignore-commit patch. Maybe printing stray output is the right thing to do, as opposed to erroring out.
2. %>(*) only works with f-e-r atoms, not with pretty-format atoms. This is ofcourse obvious from the implementation, but isn't it a little consistent?
Should we start off a new pretty-ref-formats document, where we explicitly exclude things like %ae (because of the hex overriding thing)? I don't think it's a problem if documented properly.