Re: [PATCH] t9902: Instruct git-completion.bash about a test mode

2013-01-24 Thread Jean-Noël AVILA
Le jeudi 24 janvier 2013 23:29:33, Junio C Hamano a écrit : > "Jean-Noël AVILA" writes: > > > My rational was to be sure to put the environment variable out of the > > way once the script has been sourced. I can make two alternative > > definitions of __git_list_all_commands () depending on the

Re: [PATCH] t9902: Instruct git-completion.bash about a test mode

2013-01-24 Thread Junio C Hamano
"Jean-Noël AVILA" writes: > My rational was to be sure to put the environment variable out of the > way once the script has been sourced. I can make two alternative > definitions of __git_list_all_commands () depending on the presence of > $AUTHORIZED_CMD_LIST if you are worried about performa

Re: [PATCH] t9902: Instruct git-completion.bash about a test mode

2013-01-24 Thread Jean-Noël AVILA
Le jeudi 24 janvier 2013 22:46:13, Junio C Hamano a écrit : > "Jean-Noël AVILA" writes: > > > In test mode, git completion should propose commands only if they > > belong to the list of authorized commands. > > > > Signed-off-by: Jean-Noel Avila > > --- > > > > Better show some code than try to

Re: [PATCH] t9902: Instruct git-completion.bash about a test mode

2013-01-24 Thread Junio C Hamano
"Jean-Noël AVILA" writes: > In test mode, git completion should propose commands only if they > belong to the list of authorized commands. > > Signed-off-by: Jean-Noel Avila > --- > > Better show some code than try to explain. Here is what I mean by > "filter the output git help -a". Why do yo

[PATCH] t9902: Instruct git-completion.bash about a test mode

2013-01-24 Thread Jean-Noël AVILA
In test mode, git completion should propose commands only if they belong to the list of authorized commands. Signed-off-by: Jean-Noel Avila --- Better show some code than try to explain. Here is what I mean by "filter the output git help -a". contrib/completion/git-completion.bash | 16 ++