Re: [Newbie] How to *actually* get rid of remote tracking branch?

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

 



On Nov 13, 2007 6:58 PM,  <osv@xxxxxxxxx> wrote:
> Jakub Narebski <jnareb@xxxxxxxxx> writes:
> > Steffen Prohaska wrote:
> >> It doesn't make sense to delete remote-tracking branches
> >> locally if they are still present at the remote.  The main
> >> purpose of a remote-tracking branch is to be identical to the
> >> real remote branch.
> >
> > True, but it would be nice to have an option to _exclude_ some
> > branches from fetching (for example 'html' and 'man' branches
> > of git.git), while still picking up new branches automatically
> > on fetch.
>
> Guys, could you please read man git-branch?

I understand that the man-page could be confusing, the problem is that
these examples are quite old: they made more sense when git didn't
support wildcards in refspecs.

You want an easy way to tell git to stop tracking the pu-branch. This
can be achieved by editing the [remote "origin"] section in
.git/config: remove the fetch-line containing refs/heads/* and add one
fetch line for each ref you'd like to track. But beware that you have
to add any new branches which you would like to track in the same way
(editing .git/config).

The reason git-branch -d -r doesn't do this automatically is probably
that nobody has seen a need for it to do so...

--
larsh
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[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