jgit/org.eclipse.jgit.pgm
Matthias Sohn 846ef78a02 Fix RebuildRefTree trying to add HEAD twice to RefTree
14dfa70520 fixed the problem that HEAD wasn't added to the reftree when
rebuilding the reftree in an empty repository where HEAD isn't yet
resolvable. Since non-resolvable refs are filtered out by
RefDatabase.getRefs(ALL) we have to add HEAD to the reftree explicitly
in this special case.

This fix resulted in another bug: rebuilding the reftree in a repository
which has a resolvable HEAD failed with a DirCacheNameConflictException
in RefTree.apply(). If HEAD is resolvable RefDatabase.getRefs(ALL) does
not filter out HEAD. This results in two identical CREATE commands for
HEAD which RefTree.apply() refuses to execute.

Fix this by no longer creating a duplicate CREATE command for HEAD.

See: I46cbc2611b9ae683ef7319dc46af277925dfaee5
Change-Id: I58dd6bcdef88820aa7de29761d43e2edfa18fcbe
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2016-03-05 01:03:34 +01:00
..
.settings Update dependencies to use the JGit-internal @Nullable 2015-11-09 14:27:52 -08:00
META-INF Support Amazon S3 based storage for LFS 2016-02-17 11:36:58 -05:00
resources Fix help text for option --enable of command debug-rebuild-ref-tree 2016-03-01 23:18:34 +01:00
src/org/eclipse/jgit Fix RebuildRefTree trying to add HEAD twice to RefTree 2016-03-05 01:03:34 +01:00
.classpath Set minimum required Java version to Java 7 2015-02-09 14:11:50 +01:00
.gitignore Finish removing Apache Felix maven-bundle-plugin 2010-01-12 11:46:55 -08:00
.project Enforce the use of Java5 API:s only (with a few exceptions) 2011-12-16 01:01:36 +01:00
BUCK Support LFS protocol and a file system based LFS storage 2016-02-04 17:49:43 +01:00
about.html Add missing about.html files to all shipped bundles 2011-06-08 21:51:51 +02:00
build.properties Add missing resources from source.. in build.properties 2013-10-30 17:42:38 +01:00
jgit.sh Make jgit.sh work on windows when JGIT_CLASSPATH is set 2014-12-01 14:54:17 +01:00
plugin.properties Fix plugin provider names to conform with release train requirement 2013-04-08 23:05:36 +02:00
pom.xml Support LFS protocol and a file system based LFS storage 2016-02-04 17:49:43 +01:00