avoiding fetching specific refs from a remote

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux