Subject: Re: [PATCH] rev-parse --show-prefix: add in trailing newline

From: Ross Lagerwall <[email-masked]>
Date: Tue, 10 Apr 2012 07:30:49 +0200

On 2012/04/09 21:07, Junio C Hamano wrote:
> fc68875 (t1501 (rev-parse): clarify, 2010-07-24) says it is a "possible
> bug", but I do not think the expectation of the new test added by that
> commit is entirely correct.
>
> Because the assignment will strip the trailing LF away adding an extra
> newline at the end would not matter in practice in many scripts, e.g.
>

True, and the current behavior does exactly what the man page says:
"When the command is invoked from a subdirectory, show the path of the 
current directory relative to the top-level directory."

So then perhaps the test should be removed?

Also, --show-cdup has a similar description for the man page but does 
output a newline when invoked from the root dir. Should this behavior be 
made consistent?

-- 
Ross Lagerwall