Skip to content
  • Michael Haggerty's avatar
    fetch --tags: fetch tags *in addition to* other stuff · c5a84e92
    Michael Haggerty authored and Junio C Hamano's avatar Junio C Hamano committed
    Previously, fetch's "--tags" option was considered equivalent to
    specifying the refspec "refs/tags/*:refs/tags/*" on the command line;
    in particular, it caused the remote.<name>.refspec configuration to be
    ignored.
    
    But it is not very useful to fetch tags without also fetching other
    references, whereas it *is* quite useful to be able to fetch tags *in
    addition to* other references.  So change the semantics of this option
    to do the latter.
    
    If a user wants to fetch *only* tags, then it is still possible to
    specifying an explicit refspec:
    
        git fetch <remote> 'refs/tags/*:refs/tags/*'
    
    Please note that the documentation prior to 1.8.0.3 was ambiguous
    about this aspect of "fetch --tags" behavior.  Commit
    
        f0cb2f13
    
     2012-12-14 fetch --tags: clarify documentation
    
    made the documentation match the old behavior.  This commit changes
    the documentation to match the new behavior.
    
    Signed-off-by: default avatarMichael Haggerty <mhagger@alum.mit.edu>
    Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
    c5a84e92