Question

The git remote man page explains what --tags and --no-tags does, but not the default behavior if neither is specified. What is that behavior?

Was it helpful?

Solution

After looking more at the git fetch, git config and git tag manuals, I believe the remote.<name>.tagopt config option is merely passed to git fetch by git remote. So the default behavior for git remote is identical to git fetch's default behavior:

When <refspec> stores the fetched result in remote-tracking branches, the tags that point at these branches are automatically followed. This is done by first fetching from the remote using the given <refspec>s, and if the repository has objects that are pointed by remote tags that it does not yet have, then fetch those missing tags. If the other end has tags that point at branches you are not interested in, you will not get them.

from git fetch manual

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top