Package ch.kk7.confij.source.resource
Class GitResource
- java.lang.Object
-
- ch.kk7.confij.source.resource.GitResource
-
- All Implemented Interfaces:
ch.kk7.confij.source.resource.ConfijResource
public class GitResource extends java.lang.Object implements ch.kk7.confij.source.resource.ConfijResource
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classGitResource.GitAnyResourcestatic classGitResource.GitSettings
-
Field Summary
Fields Modifier and Type Field Description protected static java.nio.file.PathTEMP_DIRprotected static java.lang.StringTEMP_DIR_PREFIX
-
Constructor Summary
Constructors Constructor Description GitResource()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.io.FilegetFileForSeed(@NonNull java.lang.String seed)protected org.eclipse.jgit.revwalk.RevCommitgetRevCommit(org.eclipse.jgit.api.Git git, GitResource.GitSettings settings)protected org.eclipse.jgit.api.GitgitClone(GitResource.GitSettings settings)protected org.eclipse.jgit.api.GitgitCloneOrFetch(GitResource.GitSettings settings)protected org.eclipse.jgit.api.GitgitFetch(org.eclipse.jgit.api.Git git, GitResource.GitSettings settings)protected org.eclipse.jgit.api.GitgitInit(GitResource.GitSettings settings)java.util.stream.Stream<ch.kk7.confij.source.resource.ConfijResource.ResourceContent>read(ch.kk7.confij.template.ValueResolver.StringResolver resolver)protected ch.kk7.confij.source.resource.ConfijResource.ResourceContentreadFile(org.eclipse.jgit.api.Git git, GitResource.GitSettings settings)
-
-
-
Field Detail
-
TEMP_DIR_PREFIX
protected static final java.lang.String TEMP_DIR_PREFIX
- See Also:
- Constant Field Values
-
TEMP_DIR
protected static final java.nio.file.Path TEMP_DIR
-
-
Method Detail
-
read
public java.util.stream.Stream<ch.kk7.confij.source.resource.ConfijResource.ResourceContent> read(ch.kk7.confij.template.ValueResolver.StringResolver resolver)
- Specified by:
readin interfacech.kk7.confij.source.resource.ConfijResource
-
getFileForSeed
public static java.io.File getFileForSeed(@NonNull @NonNull java.lang.String seed)
-
gitCloneOrFetch
protected org.eclipse.jgit.api.Git gitCloneOrFetch(GitResource.GitSettings settings)
-
gitFetch
protected org.eclipse.jgit.api.Git gitFetch(org.eclipse.jgit.api.Git git, GitResource.GitSettings settings) throws org.eclipse.jgit.api.errors.GitAPIException- Throws:
org.eclipse.jgit.api.errors.GitAPIException
-
gitClone
protected org.eclipse.jgit.api.Git gitClone(GitResource.GitSettings settings) throws org.eclipse.jgit.api.errors.GitAPIException, java.io.IOException
- Throws:
org.eclipse.jgit.api.errors.GitAPIExceptionjava.io.IOException
-
gitInit
protected org.eclipse.jgit.api.Git gitInit(GitResource.GitSettings settings) throws org.eclipse.jgit.api.errors.GitAPIException, java.io.IOException
- Throws:
org.eclipse.jgit.api.errors.GitAPIExceptionjava.io.IOException
-
getRevCommit
protected org.eclipse.jgit.revwalk.RevCommit getRevCommit(org.eclipse.jgit.api.Git git, GitResource.GitSettings settings)
-
readFile
protected ch.kk7.confij.source.resource.ConfijResource.ResourceContent readFile(org.eclipse.jgit.api.Git git, GitResource.GitSettings settings)
-
-