Re: [PATCH 12/10] Teach bash about git-repo-config.

2 messages, 2 authors, 2016-08-11 · open the first message on its own page

Re: [PATCH 12/10] Teach bash about git-repo-config.

From: Junio C Hamano <hidden>
Date: 2016-08-11 19:26:38

"Shawn O. Pearce" [off-list ref] writes:
 Yes, that's it.  I'm finally done tinkering with bash
 completion support for this week.  Total of 12 patches.
Thanks.  I saw a funky behaviour when I tried this:

	$ git pull . ap<TAB>

==>
	$ git pull . apfatal: Not a git repository: '.'

Re: [PATCH 12/10] Teach bash about git-repo-config.

From: Shawn Pearce <hidden>
Date: 2016-08-11 19:33:45

Junio C Hamano [off-list ref] wrote:
"Shawn O. Pearce" [off-list ref] writes:
quoted
 Yes, that's it.  I'm finally done tinkering with bash
 completion support for this week.  Total of 12 patches.
Thanks.  I saw a funky behaviour when I tried this:

	$ git pull . ap<TAB>

==>
	$ git pull . apfatal: Not a git repository: '.'
Doh.  Its the commit titled "Support bash completion of refs/remote".
The problem is I'm invoking git-for-each-ref wrong:

	git --git-dir=. for-each-ref ...

Clearly "." isn't a git directory.  But ./.git is.  The breakage is
the switch from git-peek-remote to git-for-each-ref.  git-peek-remote
nicely realized that "." wasn't a git directory but "./.git" was
and went into ./.git to get the refs.  I switched to for-each-ref
to get a potential speed boost (no need to dereference tags) but
broke the damn thing in the process.

I thought I had tested this for-each-ref change out.  Apparently I
missed a case.

I'll fix it tomorrow.

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