Thread (3 messages) flat view 3 messages, 2 authors, 2016-06-15

[BUG?] git remote rm repo nukes local refs for mirror repo

From: Michael J Gruber <hidden>
Date: 2016-06-15 22:45:29

I just noticed the hard way that "git remote rm repo" nukes all local
(mirrored) refs if repo had been setup with "git remote add --mirror
repo url".
Some may argue that this behaviour fits the description "deletes all
remote tracking branches" but I would claim it does not: mirrored
branches are not remote tracking branches in the proper sense.

So:
- Is this behaviour intended?
- If yes, how else would I remove a remote mirror configuration without
destroying a local repo? git config, I know, but that can't be the way.

Michael

Technical:
remote_find_tracking() in remote.c returns "branch" as the remote
tracking branch of "branch" (itself) in a mirror setup. Is this the
right thing to do?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help