Re: [PATCH v3] Support ent:relative_path

4 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: [PATCH v3] Support ent:relative_path

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:43:08

Johannes Schindelin [off-list ref] writes:
quoted
(a) In a bare repository, I believe setup.c:setup_git_directory_gently()
determines the prefix to be NULL.  This means my patch will see
ALL paths as absolute,  except :../path which will result in an error.
My point was that it feels inconsistent to take the current path into 
account in one case, but not in the other.
I do not understand your reasoning.  In a bare repository you
cannot even be in a subdirectory to begin with.

Re: [PATCH v3] Support ent:relative_path

From: Johannes Schindelin <hidden>
Date: 2016-06-15 22:43:08

Hi,

On Sat, 5 May 2007, Junio C Hamano wrote:
Johannes Schindelin [off-list ref] writes:
quoted
quoted
(a) In a bare repository, I believe 
setup.c:setup_git_directory_gently() determines the prefix to be 
NULL.  This means my patch will see ALL paths as absolute, except 
:../path which will result in an error.
My point was that it feels inconsistent to take the current path into 
account in one case, but not in the other.
I do not understand your reasoning.  In a bare repository you cannot 
even be in a subdirectory to begin with.
Exactly! That is my point. If you can do it in a working directory, but 
also with a bare repository, I find it highly confusing and inconsistent 
to have different meaning.

Ciao,
Dscho

Re: [PATCH v3] Support ent:relative_path

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:43:08

Johannes Schindelin [off-list ref] writes:
On Sat, 5 May 2007, Junio C Hamano wrote:
quoted
Johannes Schindelin [off-list ref] writes:
quoted
quoted
(a) In a bare repository, I believe 
setup.c:setup_git_directory_gently() determines the prefix to be 
NULL.  This means my patch will see ALL paths as absolute, except 
:../path which will result in an error.
My point was that it feels inconsistent to take the current path into 
account in one case, but not in the other.
I do not understand your reasoning.  In a bare repository you cannot 
even be in a subdirectory to begin with.
Exactly! That is my point. If you can do it in a working directory, but 
also with a bare repository, I find it highly confusing and inconsistent 
to have different meaning.
Sorry.  Now you confused me further.  I can do:

	cd Documentation
        git diff v1.5.0 v1.5.1 -- git.txt

Is that confusing, inconsistent and bad for the users?

Re: [PATCH v3] Support ent:relative_path

From: Johannes Schindelin <hidden>
Date: 2016-06-15 22:43:08

Hi,

On Sun, 6 May 2007, Junio C Hamano wrote:
Johannes Schindelin [off-list ref] writes:
quoted
On Sat, 5 May 2007, Junio C Hamano wrote:
quoted
Johannes Schindelin [off-list ref] writes:
quoted
quoted
(a) In a bare repository, I believe 
setup.c:setup_git_directory_gently() determines the prefix to be 
NULL.  This means my patch will see ALL paths as absolute, except 
:../path which will result in an error.
My point was that it feels inconsistent to take the current path into 
account in one case, but not in the other.
I do not understand your reasoning.  In a bare repository you cannot 
even be in a subdirectory to begin with.
Exactly! That is my point. If you can do it in a working directory, but 
also with a bare repository, I find it highly confusing and inconsistent 
to have different meaning.
Sorry.  Now you confused me further.  I can do:

	cd Documentation
        git diff v1.5.0 v1.5.1 -- git.txt

Is that confusing, inconsistent and bad for the users?
Well, I am partly at fault that you _can_ execute git-diff outside of a 
repository.

But given the _arguments_ you give to git-diff as above, I'd expect it to 
actually care about the working directory. IOW I would _not_ expect this 
to work outside of a working directory (even if it does).

Ciao,
Dscho
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help