Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-20 Thread Junio C Hamano
Marc Khouzam writes: >> This one is already merged to 'next'. > > Awesome! I didn't notice. > > If I want to suggest an improvement (like checking if the bash > script is available), do I just post a patch here? Yes, as a follow-up patch (or two). Thanks. -- To unsubscribe from this list: send

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-20 Thread Marc Khouzam
On Tue, Nov 20, 2012 at 10:15 AM, Felipe Contreras wrote: > On Tue, Nov 20, 2012 at 3:58 PM, Marc Khouzam wrote: > >> Hi, >> >> since there doesn't seem to be an agreement that the approach to achieve tcsh >> git-completion would be useful for zsh (the other possible shell that could >> use >> i

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-20 Thread Marc Khouzam
On Sat, Nov 17, 2012 at 1:01 PM, Felipe Contreras wrote: > >> I gather that using a wrapper for zsh causes concerns about >> backwards-compatibility. > > I don't see any concerns. > >> if [[ -n ${ZSH_VERSION-} ]]; then >> # replace below by zsh completion commands calling `bash >> ${HOME}/.git-c

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-17 Thread Felipe Contreras
On Sat, Nov 17, 2012 at 6:15 PM, Marc Khouzam wrote: > On Fri, Nov 16, 2012 at 4:56 PM, Felipe Contreras > wrote: >> On Fri, Nov 16, 2012 at 10:20 PM, Junio C Hamano wrote: >> >>> The point is not about the quality of zsh's emulation >>> of (k)sh when it is run under that mode, but is about not

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-17 Thread Marc Khouzam
On Fri, Nov 16, 2012 at 4:56 PM, Felipe Contreras wrote: > On Fri, Nov 16, 2012 at 10:20 PM, Junio C Hamano wrote: > >> The point is not about the quality of zsh's emulation >> of (k)sh when it is run under that mode, but is about not having to >> have that logic in bash-only part in the first pl

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-17 Thread SZEDER Gábor
On Sat, Nov 17, 2012 at 12:46:27PM +0100, Felipe Contreras wrote: > On Sat, Nov 17, 2012 at 11:56 AM, SZEDER Gábor wrote: > > On Fri, Nov 16, 2012 at 10:46:16PM +0100, Felipe Contreras wrote: > > >> But even in that case, if push comes to shoves, this zsh wrapper can > >> ultimately read COMPREPL

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-17 Thread Felipe Contreras
On Sat, Nov 17, 2012 at 11:56 AM, SZEDER Gábor wrote: > On Fri, Nov 16, 2012 at 10:46:16PM +0100, Felipe Contreras wrote: >> But even in that case, if push comes to shoves, this zsh wrapper can >> ultimately read COMPREPLY and figure things backwards, as even more >> previous versions did: >> >>

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-17 Thread SZEDER Gábor
On Fri, Nov 16, 2012 at 10:46:16PM +0100, Felipe Contreras wrote: > On Fri, Nov 16, 2012 at 10:22 PM, SZEDER Gábor wrote: > > On Fri, Nov 16, 2012 at 10:03:41PM +0100, Felipe Contreras wrote: > > >> > As I understand the main issues with using the completion script with > >> > zsh are the various

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Felipe Contreras
On Fri, Nov 16, 2012 at 10:20 PM, Junio C Hamano wrote: > SZEDER Gábor writes: > >> For zsh, perhaps? > > Yeah, I was wondering about that. > > If we make zsh completion read output from a little stub in bash > completion, just like Felipe steered this series for tcsh, we do not > have to worry a

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Felipe Contreras
On Fri, Nov 16, 2012 at 10:22 PM, SZEDER Gábor wrote: > On Fri, Nov 16, 2012 at 10:03:41PM +0100, Felipe Contreras wrote: >> > As I understand the main issues with using the completion script with >> > zsh are the various little incompatibilities between the two shells >> > and bugs in zsh's emul

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread SZEDER Gábor
On Fri, Nov 16, 2012 at 10:03:41PM +0100, Felipe Contreras wrote: > On Fri, Nov 16, 2012 at 9:40 PM, SZEDER Gábor wrote: > > On Fri, Nov 16, 2012 at 09:04:06PM +0100, Felipe Contreras wrote: > >> > I agree, and this is why I made the proposed > >> > __git_complete_with_output () generic. That way

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Junio C Hamano
SZEDER Gábor writes: > For zsh, perhaps? Yeah, I was wondering about that. If we make zsh completion read output from a little stub in bash completion, just like Felipe steered this series for tcsh, we do not have to worry about "zsh does not split words unless emulating a shell and here is a w

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Felipe Contreras
On Fri, Nov 16, 2012 at 9:40 PM, SZEDER Gábor wrote: > On Fri, Nov 16, 2012 at 09:04:06PM +0100, Felipe Contreras wrote: >> > I agree, and this is why I made the proposed >> > __git_complete_with_output () generic. That way it could be >> > used by other shells or programs. But at this time, onl

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread SZEDER Gábor
On Fri, Nov 16, 2012 at 09:04:06PM +0100, Felipe Contreras wrote: > > I agree, and this is why I made the proposed > > __git_complete_with_output () generic. That way it could be > > used by other shells or programs. But at this time, only tcsh > > would make use of it. > > > > If you think havin

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Felipe Contreras
On Fri, Nov 16, 2012 at 7:20 PM, Marc Khouzam wrote: > On Fri, Nov 16, 2012 at 12:18 PM, Felipe Contreras > wrote: >> On Fri, Nov 16, 2012 at 4:48 PM, Marc Khouzam wrote: >>> On Fri, Nov 16, 2012 at 10:33 AM, Felipe Contreras >>> wrote: >> Is it possible to just check if this is a login sh

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Marc Khouzam
On Fri, Nov 16, 2012 at 12:18 PM, Felipe Contreras wrote: > On Fri, Nov 16, 2012 at 4:48 PM, Marc Khouzam wrote: >> On Fri, Nov 16, 2012 at 10:33 AM, Felipe Contreras >> wrote: > >>> Is it possible to just check if this is a login shell? >> >> I think it would be nice to allow the user to manual

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Felipe Contreras
On Fri, Nov 16, 2012 at 4:48 PM, Marc Khouzam wrote: > On Fri, Nov 16, 2012 at 10:33 AM, Felipe Contreras > wrote: >> Is it possible to just check if this is a login shell? > > I think it would be nice to allow the user to manually > source git-completion.tcsh, in case they want to make > manual

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Marc Khouzam
On Fri, Nov 16, 2012 at 10:33 AM, Felipe Contreras wrote: > On Fri, Nov 16, 2012 at 3:39 PM, Marc Khouzam wrote: >> On Thu, Nov 15, 2012 at 8:41 PM, Felipe Contreras >> wrote: >>> On Thu, Nov 15, 2012 at 12:51 PM, Marc Khouzam >>> wrote: The current tcsh-completion support for Git, as can

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Felipe Contreras
On Fri, Nov 16, 2012 at 3:39 PM, Marc Khouzam wrote: > On Thu, Nov 15, 2012 at 8:41 PM, Felipe Contreras > wrote: >> On Thu, Nov 15, 2012 at 12:51 PM, Marc Khouzam >> wrote: >>> The current tcsh-completion support for Git, as can be found on the >>> Internet, takes the approach of defining the

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-16 Thread Marc Khouzam
On Thu, Nov 15, 2012 at 8:41 PM, Felipe Contreras wrote: > On Thu, Nov 15, 2012 at 12:51 PM, Marc Khouzam wrote: >> The current tcsh-completion support for Git, as can be found on the >> Internet, takes the approach of defining the possible completions >> explicitly. This has the obvious draw-ba

Re: [PATCH] tcsh-completion re-using git-completion.bash

2012-11-15 Thread Felipe Contreras
On Thu, Nov 15, 2012 at 12:51 PM, Marc Khouzam wrote: > The current tcsh-completion support for Git, as can be found on the > Internet, takes the approach of defining the possible completions > explicitly. This has the obvious draw-back to require constant > updating as the Git code base evolves.

[PATCH] tcsh-completion re-using git-completion.bash

2012-11-15 Thread Marc Khouzam
The current tcsh-completion support for Git, as can be found on the Internet, takes the approach of defining the possible completions explicitly. This has the obvious draw-back to require constant updating as the Git code base evolves. The approach taken by this commit is to to re-use the advance