git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Keith Smiley <k@keith.so>
To: Todd Zullinger <tmz@pobox.com>
Cc: git@vger.kernel.org, "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>,
	"Kevin Daudt" <me@ikke.info>
Subject: Re: [PATCH] completion: restore 'remote rm'
Date: Fri, 29 Dec 2017 08:49:49 -0800	[thread overview]
Message-ID: <20171229164949.GA48812@bryant.local> (raw)
In-Reply-To: <20171229135240.GQ3693@zaya.teonanacatl.net>

Updated:

e17dba8fe1 ("remote: prefer subcommand name 'remove' to
'rm'", 2012-09-06) removed the 'rm' subcommand from
completion.  The 'remote rm' subcommand is still supported
and not planned to be removed.  Offer completions for it.

Signed-off-by: Keith Smiley <k@keith.so>
---
 contrib/completion/git-completion.bash | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 3683c772c5586..3e9044087e6ba 100644
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -2665,7 +2665,7 @@ _git_config ()
 _git_remote ()
 {
 	local subcommands="
-		add rename remove set-head set-branches
+		add rename remove rm set-head set-branches
 		get-url set-url show prune update
 		"
 	local subcommand="$(__git_find_on_cmdline "$subcommands")"

--
Keith Smiley

On 12/29, Todd Zullinger wrote:
>Keith Smiley wrote:
>> It looks like that was just about preferring remove in documentation
>> and the like, I think it would still make sense to have both for
>> completion since rm is still supported.
>
>I read it as a first step in a long process to eventually
>remove 'remote rm', but if that's never intended, then sure,
>restoring completion for it seems reasonable.
>
>It would be good to hear from those who know or recall the
>intention.
>
>I think we should only complete the preferred subcommand.
>That encourages use of 'remote remove' even if 'remote rm'
>will stay forever to avoid breaking existing scripts.
>
>If it does make sense to restore completion, adding a link
>back to e17dba8fe1 and explaining why the completion is
>being restored would be good.  Reading the commit message
>now makes it sound like 'remote rm' was never present and is
>being added to correct an oversight.
>
>Maybe something like:
>
>    completion: restore 'remote rm'
>
>    e17dba8fe1 ("remote: prefer subcommand name 'remove' to
>    'rm'", 2012-09-06) removed the 'rm' subcommand from
>    completion.  The 'remote rm' subcommand is still supported
>    and not planned to be removed.  Offer completions for it.
>
>I also noticed that in your original commit that you say
>"list of removes as remove does." That should be "remotes"
>instead of "removes" there. -- I've made that typo myself
>quite often. :)
>
>-- 
>Todd
>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>There are no stupid questions, but there are a LOT of inquisitive
>idiots.
>    -- Demotivators (www.despair.com)
>

  reply	other threads:[~2017-12-29 16:49 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-29  2:01 [PATCH] Add shell completion for git remote rm Keith Smiley
2017-12-29  3:29 ` Todd Zullinger
2017-12-29  4:19   ` Keith Smiley
2017-12-29 13:52     ` Todd Zullinger
2017-12-29 16:49       ` Keith Smiley [this message]
2017-12-29 22:48       ` SZEDER Gábor
2017-12-29 23:19         ` Keith Smiley
2017-12-29 23:20         ` Ævar Arnfjörð Bjarmason
2017-12-30  0:52           ` Todd Zullinger
2017-12-30 12:19             ` Ævar Arnfjörð Bjarmason
2017-12-31 20:44               ` Keith Smiley
2018-01-03 19:24               ` Junio C Hamano
2018-01-15 21:43                 ` Keith Smiley
2018-01-16 10:02                   ` Duy Nguyen
2018-01-16 18:57                     ` Junio C Hamano
2018-01-17  0:44                       ` Duy Nguyen
2018-01-17  6:17                         ` Kevin Daudt
2018-01-17  9:48                           ` Duy Nguyen
2018-07-16 13:12                             ` Keith Smiley
2018-01-17 18:20                         ` Junio C Hamano
2018-01-01 23:46     ` Duy Nguyen
2017-12-29  6:00 ` Kevin Daudt
2017-12-29  6:21   ` Keith Smiley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171229164949.GA48812@bryant.local \
    --to=k@keith.so \
    --cc=git@vger.kernel.org \
    --cc=me@ikke.info \
    --cc=pclouds@gmail.com \
    --cc=tmz@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).