Class RebuildCommitGraph

java.lang.Object
org.eclipse.jgit.pgm.TextBuiltin
org.eclipse.jgit.pgm.debug.RebuildCommitGraph

class RebuildCommitGraph extends TextBuiltin
Recreates a repository from another one's commit graph.

Do not run this on a repository unless you want to destroy it.

To create the input files, in the source repository use:

 git for-each-ref >in.refs
 git log --all '--pretty=format:%H %ct %P' >in.dag
 

Run the rebuild in either an empty repository, or a clone of the source. Any missing commits (which might be the entire graph) will be created. All refs will be modified to match the input exactly, which means some refs may be deleted from the current repository.