fetch <repo> <branch>:<branch> fetches tags?

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

 



Is this the intended behavior?

I'm pretty sure this was discussed recently on the list.
My understanding was that tags would only be fetched
automatically if a remote tracking branch was configured.

$ cat .git/config
[core]
        repositoryformatversion = 0
        filemode = true
        bare = false
        logallrefupdates = true


I expect these to fetch tags automatically (and they do):

   git fetch
   git pull
   git fetch <repo>
   git pull <repo>

I expect these to _not_ fetch tags (and they don't):

   git fetch <repo> <branch>
   git pull <repo> <branch>

But, I did not expect these to fetch tags:

   git fetch <repo> <branch>:<branch>
   git pull <repo> <branch>:<branch>


The association I am making here is between manually specifying
the repo and branch implying "don't automatically fetch tags",
and fetch/pull automatically determining the branch (and repo)
implying "automatically fetch tags".

There is nothing automatic about that last form of fetch.

I know there is --no-tags, and I know I can do

   git fetch <repo> <branch>
   git branch <branch> FETCH_HEAD

But neither are what I expected to have to do. So I guess the
colon notation implies remote tracking? I'm not sure I want
the tags by default when I call fetch this way. In this
instance I definitely did not want them.

-brandon

-
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