threads / patch / 22340

patchbash: don't offer remote transport helpers as subcommands

Subject: [PATCH] bash: don't offer remote transport helpers as subcommands

## tl;dr

2 messages between Jan 22, 2010 and Jan 28, 2010. Diffs are folded; open one to read it.

replies: 1people: 2as markdown or json

SZEDER Gábor· Jan 22, 2010, 10:54 UTC · lore

Since commits a2d725b7 (Use an external program to implement fetching with curl, 2009-08-05) and c9e388bb (Make the "traditionally-supported" URLs a special case, 2009-09-03) remote transport helpers like 'remote-ftp' and 'remote-curl' are offered by the completion script as available subcommands. Not good, since they are helpers, therefore should not be offered, so filter them out.

Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
---

Maybe maint-worthy? 1.6.5 was the first release with this bug, but nobody complained since then.

 contrib/completion/git-completion.bash |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
Show changes to contrib/completion/git-completion.bash +1 −0
diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 9651720..7def62c 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -568,6 +568,7 @@ __git_list_porcelain_commands ()
 		read-tree)        : plumbing;;
 		receive-pack)     : plumbing;;
 		reflog)           : plumbing;;
+		remote-*)         : transport;;
 		repo-config)      : deprecated;;
 		rerere)           : plumbing;;
 		rev-list)         : plumbing;;
-- 
1.6.6.1.361.gc5121
Shawn O. Pearce· Jan 28, 2010, 15:19 UTC · re: SZEDER Gábor · lore

Re: [PATCH] bash: don't offer remote transport helpers as subcommands

SZEDER G??bor <szeder@ira.uka.de> wrote:
Show 12 quoted lines
> Since commits a2d725b7 (Use an external program to implement fetching
> with curl, 2009-08-05) and c9e388bb (Make the
> "traditionally-supported" URLs a special case, 2009-09-03) remote
> transport helpers like 'remote-ftp' and 'remote-curl' are offered by the
> completion script as available subcommands.  Not good, since they are
> helpers, therefore should not be offered, so filter them out.
> 
> Signed-off-by: SZEDER G??bor <szeder@ira.uka.de>
> ---
> 
> Maybe maint-worthy?  1.6.5 was the first release with this bug, but
> nobody complained since then.
Yup, should be in maint.
Acked-by: Shawn O. Pearce <spearce@spearce.org>
 
Show 17 quoted lines
>  contrib/completion/git-completion.bash |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
> index 9651720..7def62c 100755
> --- a/contrib/completion/git-completion.bash
> +++ b/contrib/completion/git-completion.bash
> @@ -568,6 +568,7 @@ __git_list_porcelain_commands ()
>  		read-tree)        : plumbing;;
>  		receive-pack)     : plumbing;;
>  		reflog)           : plumbing;;
> +		remote-*)         : transport;;
>  		repo-config)      : deprecated;;
>  		rerere)           : plumbing;;
>  		rev-list)         : plumbing;;
> -- 
> 1.6.6.1.361.gc5121
-- 
Shawn.

← back to recent threads