git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jason Karns <jason.karns@gmail.com>
To: szeder.dev@gmail.com
Cc: git@vger.kernel.org, gitster@pobox.com, peff@peff.net
Subject: Re: [PATCH] completion: optionally disable checkout DWIM
Date: Thu, 29 Jun 2017 16:03:13 -0400	[thread overview]
Message-ID: <CAKNmmv16WG=8=66B8+paiRsjqFKjRKCLPyjEaHkNPsXaOhBCYQ@mail.gmail.com> (raw)

> We could discern between more than just empty vs. non-empty state of
> the environment variable, e.g.:
>
>  - if empty/unset, then include "DWIM" suggestions.
>  - if set to 'config', then query the 'completion.checkoutNoGuess'
>    configuration variable, and omit "DWIM" suggestions if its true.
>  - if set to something else, then omit "DWIM" suggestions.

> Then users can themselves decide, whether the per-repo configurability
> is worth the overhead of running 'git config'.

I would _definitely_ appreciate this feature. Firstly, thank you for
the addition of the environment variable. It is indeed much better
than the --no-guess flag.

However, I'm in a situation where I very much prefer the DWIM behavior
for nearly all of my repos. However, a very few repos have LOTS of
branches. And I only wish to disable DWIM in those few repos.

I attempted to create an alias (`git config alias.co 'checkout
--no-guess'`) in those specific repos. However, that turned out to be
foolish since I believe the alias parsing doesn't occur until _after_
the shell completion script runs (thus the --no-guess is not actually
present in the command parsed by the completion script).

So I'm back to very much wanting the ability to disable DWIM
repo-specific via git-config; and am willing to pay the git-config tax
as necessary.

             reply	other threads:[~2017-06-29 20:03 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-29 20:03 Jason Karns [this message]
  -- strict thread matches above, loose matches on Subject: below --
2017-04-20 20:12 [PATCH] completion: optionally disable checkout DWIM Jeff King
2017-04-21  5:01 ` Junio C Hamano
2017-04-21  5:03   ` Jeff King
2017-04-21  5:30     ` Junio C Hamano
2017-04-21 20:14   ` SZEDER Gábor
2017-04-21 20:19     ` Jeff King
2017-04-22 17:32       ` SZEDER Gábor
2017-04-21  7:25 ` Jacob Keller

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='CAKNmmv16WG=8=66B8+paiRsjqFKjRKCLPyjEaHkNPsXaOhBCYQ@mail.gmail.com' \
    --to=jason.karns@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    --cc=szeder.dev@gmail.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).