From: Jacob Keller <email@example.com> To: Git mailing list <firstname.lastname@example.org> Subject: avoiding fetching specific refs from a remote Date: Tue, 4 Aug 2020 14:53:30 -0700 [thread overview] Message-ID: <CA+P7+xpokJ3Z4xZ9ibCBpBO65D1v-AD6_JknprGUsEDxEvMGGw@mail.gmail.com> (raw) Hi, I've recently had a few repositories switch their default branch from master to main. Currently, for backwards compatibility these repositories have kept master around as a synonym for main. It's unclear when this will be removed. This results in the annoying completion behavior where: $git checkout ma<TAB> main master Essentially, because both main and master have similar names, tab completion requires remembering to type one additional character than I am used to. I'd like to be able to customize my pull so that I either (a) exclude the reference when performing a fetch, or (b) exclude the reference when tab completing. I don't know if there is any mechanism already in place to do this, so I'm trying to figure out which one would be most preferable on the list? something like adding a remote.<name>.excludeRefs which would allow specifying a set of references to exclude from matching the refspec.. I realize I could customize the refspec to list the set of things I want, but then I would miss any potential future branches until I updated my remote config again. I would like to be able to remove this annoyance for myself and colleagues. It seems to me the easiest solution would be the sort of exclude option, as this enables generally skipping out on specific refs, and could be useful beyond just this initial impetus. Thanks, Jake
next reply other threads:[~2020-08-04 21:53 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-08-04 21:53 Jacob Keller [this message] 2020-08-05 6:37 ` Jeff King 2020-08-05 16:22 ` Junio C Hamano 2020-08-05 20:34 ` Jacob Keller 2020-08-05 20:34 ` Jeff King 2020-08-05 20:31 ` Jacob Keller 2020-08-05 22:12 ` Philippe Blain 2020-08-07 8:04 ` Eric Wong 2020-08-12 22:04 ` Jacob Keller 2020-08-13 8:48 ` Jeff King
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=CA+P7+xpokJ3Z4xZ9ibCBpBO65D1v-AD6_JknprGUsEDxEvMGGw@mail.gmail.com \ --email@example.com \ --firstname.lastname@example.org \ --subject='Re: avoiding fetching specific refs from a remote' \ /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
Code repositories for project(s) associated with this 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).