Re: [PATCH] An alias that starts with "!!" runs in the current directory.

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

Re: [PATCH] An alias that starts with "!!" runs in the current directory.

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:48:45

Eli Barzilay [off-list ref] writes:
It looks like setup_git_directory_gently() returns the original CWD,...
It is designed to return what we internally call "prefix".  You however
have to be careful as it can return NULL or an empty string when you are
already at the top of the working tree.

Re: [PATCH] An alias that starts with "!!" runs in the current directory.

From: Eli Barzilay <hidden>
Date: 2016-06-15 22:48:45

On May  5, Junio C Hamano wrote:
Eli Barzilay [off-list ref] writes:
quoted
It looks like setup_git_directory_gently() returns the original CWD,...
It is designed to return what we internally call "prefix".  You
however have to be careful as it can return NULL or an empty string
when you are already at the top of the working tree.
OK, in this case it looks like it should work as expected.  At least
provided that chdir("") stays in the same directory -- and given the
call at the end of handle_alias(), it looks like this assumption is
already made.  Does this sound right?

-- 
          ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
                    http://barzilay.org/                   Maze is Life!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help