]> source.dussan.org Git - jgit.git/commit
Refactor repository construction to builder class 59/959/1
authorShawn O. Pearce <spearce@spearce.org>
Thu, 24 Jun 2010 16:07:53 +0000 (09:07 -0700)
committerShawn O. Pearce <spearce@spearce.org>
Sat, 26 Jun 2010 00:58:40 +0000 (17:58 -0700)
commit532421d98925f23ddaa63c8d5f22be24879a6385
treef22425b408d55019bacab3a20adae68e390528bd
parent8f46ee4870d0a49fcce1d0cb2b8e2aee9aaafee1
Refactor repository construction to builder class

The new FileRepositoryBuilder class helps applications to construct
a properly configured FileRepository, with properties assumed based
upon the standard Git rules for the local filesystem.

To better support simple command line applications, environment
variable handling and repository searching was moved into this
builder class.

The change gets rid of the ever-growing FileRepository constructor
variants, and the multitude of java.io.File typed parameters,
by using simple named setter methods.

Change-Id: I17e8e0392ad1dbf6a90a7eb49a6d809388d27e4c
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Main.java
org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/RepositorySetupWorkDirTest.java
org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/T0003_Basic.java
org.eclipse.jgit/resources/org/eclipse/jgit/JGitText.properties
org.eclipse.jgit/src/org/eclipse/jgit/JGitText.java
org.eclipse.jgit/src/org/eclipse/jgit/lib/BaseRepositoryBuilder.java [new file with mode: 0644]
org.eclipse.jgit/src/org/eclipse/jgit/lib/FileRepository.java
org.eclipse.jgit/src/org/eclipse/jgit/lib/FileRepositoryBuilder.java [new file with mode: 0644]
org.eclipse.jgit/src/org/eclipse/jgit/lib/Repository.java
org.eclipse.jgit/src/org/eclipse/jgit/lib/RepositoryBuilder.java [new file with mode: 0644]