Subject: Re: [RFC 00/14] Allow fetch-pack to send ref names (globs allowed)

From: Junio C Hamano <[email-masked]>
Date: Wed, 08 Feb 2017 16:26:33 -0800

Jonathan Tan <[email-masked]> writes:

> Usages of the list of remote refs or the remote-local ref
> map are updated as follows:
>  - check_not_current_branch (which checks that the current branch is not
>    affected by the fetch) is performed both on the original ref map (to
>    die before the fetch if we can, as an optimization) and on the new
>    ref map (since the new ref map is the one actually applied).

OK.

>  - Pruning is done based on the new ref map.

OK.  As that is what eventually gets "installed" on the local side,
it makes sense to become consistent with that set, not the set the
original server gave you.

>  - backfill_tags (for tag following) is performed using the original
>    list of remote refs because the new list of fetched refs is not
>    guaranteed to contain tag information. (Since backfill_tags performs
>    another fetch, it does not need to be fully consistent with the
>    just-returned packfile.)

This smells correct but I need to think about this one a bit more.

Overall I think the strategy is agreeable.