diff options
author | Shawn O. Pearce <spearce@spearce.org> | 2011-03-14 08:53:41 -0700 |
---|---|---|
committer | Shawn O. Pearce <spearce@spearce.org> | 2011-03-14 08:53:41 -0700 |
commit | 3b91e3fe49154383006b83f900d68efee1c1777a (patch) | |
tree | 600563bf91e7b4c34f9bc2f4057ada64ecea0d0f /org.eclipse.jgit.pgm/src | |
parent | 9b941d017228a236d733abce183b2fecef69d682 (diff) | |
download | jgit-3b91e3fe49154383006b83f900d68efee1c1777a.tar.gz jgit-3b91e3fe49154383006b83f900d68efee1c1777a.zip |
Always fetch tags during clone
C Git always fetches tags during clone, even if the tag doesn't
point to an object that was fetched by the branch specifications.
Match that behavior, as users expect it.
Bug: 326611
Change-Id: I81a82b7359a9649f18a172219da44ed54e77ca2f
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'org.eclipse.jgit.pgm/src')
-rw-r--r-- | org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Clone.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Clone.java b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Clone.java index 73530efca1..de430294fb 100644 --- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Clone.java +++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Clone.java @@ -69,6 +69,7 @@ import org.eclipse.jgit.storage.file.FileRepository; import org.eclipse.jgit.transport.FetchResult; import org.eclipse.jgit.transport.RefSpec; import org.eclipse.jgit.transport.RemoteConfig; +import org.eclipse.jgit.transport.TagOpt; import org.eclipse.jgit.transport.Transport; import org.eclipse.jgit.transport.URIish; import org.kohsuke.args4j.Argument; @@ -143,6 +144,7 @@ class Clone extends AbstractFetchCommand { final Transport tn = Transport.open(db, remoteName); final FetchResult r; try { + tn.setTagOpt(TagOpt.FETCH_TAGS); r = tn.fetch(new TextProgressMonitor(), null); } finally { tn.close(); |