public final class JGitUtil extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
JGitUtil.JGitPathInfo |
static class |
JGitUtil.PathType |
| Modifier and Type | Method and Description |
|---|---|
static List<org.eclipse.jgit.lib.Ref> |
branchList(org.eclipse.jgit.api.Git git) |
static List<org.eclipse.jgit.lib.Ref> |
branchList(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.api.ListBranchCommand.ListMode listMode) |
static org.uberfire.java.nio.file.attribute.BasicFileAttributes |
buildBasicAttributes(JGitFileSystem fs,
String branchName,
String path) |
static org.uberfire.java.nio.base.attributes.HiddenAttributes |
buildHiddenAttributes(JGitFileSystem fileSystem,
String branchName,
String path) |
static org.uberfire.java.nio.base.version.VersionAttributes |
buildVersionAttributes(JGitFileSystem fs,
String branchName,
String path) |
static org.uberfire.commons.data.Pair<JGitUtil.PathType,org.eclipse.jgit.lib.ObjectId> |
checkPath(org.eclipse.jgit.api.Git git,
String branchName,
String path) |
static void |
cherryPick(org.eclipse.jgit.lib.Repository repo,
String targetBranch,
String... _commits) |
static org.eclipse.jgit.api.Git |
cloneRepository(File repoFolder,
String fromURI,
boolean bare,
org.eclipse.jgit.transport.CredentialsProvider credentialsProvider) |
static boolean |
commit(org.eclipse.jgit.api.Git git,
String branchName,
CommitInfo commitInfo,
boolean amend,
CommitContent content) |
static void |
commit(org.eclipse.jgit.api.Git git,
String branchName,
String name,
String email,
String message,
TimeZone timeZone,
Date when,
boolean amend,
Map<String,File> content) |
static void |
createBranch(org.eclipse.jgit.api.Git git,
String source,
String target) |
static org.eclipse.jgit.dircache.DirCache |
createTemporaryIndexForContent(org.eclipse.jgit.api.Git git,
Map<String,org.eclipse.jgit.lib.ObjectId> content) |
static void |
deleteBranch(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.lib.Ref branch) |
static void |
fetchRepository(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.transport.CredentialsProvider credentialsProvider,
org.eclipse.jgit.transport.RefSpec... refSpecs) |
static String |
fixPath(String path) |
static void |
gc(org.eclipse.jgit.api.Git git) |
static org.eclipse.jgit.lib.Ref |
getBranch(org.eclipse.jgit.api.Git git,
String name) |
static List<org.eclipse.jgit.revwalk.RevCommit> |
getCommits(org.eclipse.jgit.api.Git repo,
String branch,
org.eclipse.jgit.lib.ObjectId startRange,
org.eclipse.jgit.lib.ObjectId endRange) |
static org.eclipse.jgit.revwalk.RevCommit |
getCommonAncestor(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.lib.ObjectId rightCommit,
org.eclipse.jgit.lib.ObjectId leftCommit) |
static List<org.eclipse.jgit.diff.DiffEntry> |
getDiff(org.eclipse.jgit.lib.Repository repo,
org.eclipse.jgit.lib.ObjectId oldRef,
org.eclipse.jgit.lib.ObjectId newRef) |
static org.eclipse.jgit.revwalk.RevCommit |
getLastCommit(org.eclipse.jgit.api.Git git,
String branchName) |
static org.eclipse.jgit.lib.ObjectId |
getTreeRefObjectId(org.eclipse.jgit.lib.Repository repo,
String treeRef) |
static boolean |
hasBranch(org.eclipse.jgit.api.Git git,
String branchName) |
static List<JGitUtil.JGitPathInfo> |
listPathContent(org.eclipse.jgit.api.Git git,
String branchName,
String path) |
static org.eclipse.jgit.api.Git |
newRepository(File repoFolder,
boolean bare) |
static org.eclipse.jgit.api.Git |
newRepository(File repoFolder,
boolean bare,
File hookDir) |
static void |
pushRepository(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.transport.CredentialsProvider credentialsProvider,
String origin,
boolean force) |
static InputStream |
resolveInputStream(org.eclipse.jgit.api.Git git,
String treeRef,
String path) |
static org.eclipse.jgit.lib.ObjectId |
resolveObjectId(org.eclipse.jgit.api.Git git,
String name) |
static org.eclipse.jgit.lib.ObjectId[] |
resolveObjectIds(org.eclipse.jgit.api.Git git,
String... ids) |
static JGitUtil.JGitPathInfo |
resolvePath(org.eclipse.jgit.api.Git git,
String branchName,
String path) |
static void |
syncRepository(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.transport.CredentialsProvider credentialsProvider,
String origin,
boolean force) |
public static org.eclipse.jgit.api.Git newRepository(File repoFolder, boolean bare) throws org.uberfire.java.nio.IOException
org.uberfire.java.nio.IOExceptionpublic static org.eclipse.jgit.api.Git newRepository(File repoFolder, boolean bare, File hookDir) throws org.uberfire.java.nio.IOException
org.uberfire.java.nio.IOExceptionpublic static List<org.eclipse.jgit.lib.Ref> branchList(org.eclipse.jgit.api.Git git)
public static List<org.eclipse.jgit.lib.Ref> branchList(org.eclipse.jgit.api.Git git, org.eclipse.jgit.api.ListBranchCommand.ListMode listMode)
public static InputStream resolveInputStream(org.eclipse.jgit.api.Git git, String treeRef, String path)
public static org.eclipse.jgit.api.Git cloneRepository(File repoFolder, String fromURI, boolean bare, org.eclipse.jgit.transport.CredentialsProvider credentialsProvider)
public static void fetchRepository(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.transport.CredentialsProvider credentialsProvider,
org.eclipse.jgit.transport.RefSpec... refSpecs)
throws org.eclipse.jgit.api.errors.InvalidRemoteException
org.eclipse.jgit.api.errors.InvalidRemoteExceptionpublic static void syncRepository(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.transport.CredentialsProvider credentialsProvider,
String origin,
boolean force)
throws org.eclipse.jgit.api.errors.InvalidRemoteException
org.eclipse.jgit.api.errors.InvalidRemoteExceptionpublic static void pushRepository(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.transport.CredentialsProvider credentialsProvider,
String origin,
boolean force)
throws org.eclipse.jgit.api.errors.InvalidRemoteException
org.eclipse.jgit.api.errors.InvalidRemoteExceptionpublic static void cherryPick(org.eclipse.jgit.lib.Repository repo,
String targetBranch,
String... _commits)
public static org.eclipse.jgit.lib.ObjectId getTreeRefObjectId(org.eclipse.jgit.lib.Repository repo,
String treeRef)
public static List<org.eclipse.jgit.diff.DiffEntry> getDiff(org.eclipse.jgit.lib.Repository repo, org.eclipse.jgit.lib.ObjectId oldRef, org.eclipse.jgit.lib.ObjectId newRef)
public static List<org.eclipse.jgit.revwalk.RevCommit> getCommits(org.eclipse.jgit.api.Git repo, String branch, org.eclipse.jgit.lib.ObjectId startRange, org.eclipse.jgit.lib.ObjectId endRange)
public static void commit(org.eclipse.jgit.api.Git git,
String branchName,
String name,
String email,
String message,
TimeZone timeZone,
Date when,
boolean amend,
Map<String,File> content)
public static boolean commit(org.eclipse.jgit.api.Git git,
String branchName,
CommitInfo commitInfo,
boolean amend,
CommitContent content)
public static org.eclipse.jgit.dircache.DirCache createTemporaryIndexForContent(org.eclipse.jgit.api.Git git,
Map<String,org.eclipse.jgit.lib.ObjectId> content)
public static org.eclipse.jgit.lib.ObjectId resolveObjectId(org.eclipse.jgit.api.Git git,
String name)
public static org.eclipse.jgit.lib.ObjectId[] resolveObjectIds(org.eclipse.jgit.api.Git git,
String... ids)
public static org.eclipse.jgit.lib.Ref getBranch(org.eclipse.jgit.api.Git git,
String name)
public static void deleteBranch(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.lib.Ref branch)
public static org.uberfire.java.nio.base.version.VersionAttributes buildVersionAttributes(JGitFileSystem fs, String branchName, String path)
public static org.uberfire.java.nio.file.attribute.BasicFileAttributes buildBasicAttributes(JGitFileSystem fs, String branchName, String path)
public static void createBranch(org.eclipse.jgit.api.Git git,
String source,
String target)
public static void gc(org.eclipse.jgit.api.Git git)
public static boolean hasBranch(org.eclipse.jgit.api.Git git,
String branchName)
public static org.eclipse.jgit.revwalk.RevCommit getLastCommit(org.eclipse.jgit.api.Git git,
String branchName)
public static org.eclipse.jgit.revwalk.RevCommit getCommonAncestor(org.eclipse.jgit.api.Git git,
org.eclipse.jgit.lib.ObjectId rightCommit,
org.eclipse.jgit.lib.ObjectId leftCommit)
public static org.uberfire.java.nio.base.attributes.HiddenAttributes buildHiddenAttributes(JGitFileSystem fileSystem, String branchName, String path)
public static org.uberfire.commons.data.Pair<JGitUtil.PathType,org.eclipse.jgit.lib.ObjectId> checkPath(org.eclipse.jgit.api.Git git, String branchName, String path)
public static JGitUtil.JGitPathInfo resolvePath(org.eclipse.jgit.api.Git git, String branchName, String path)
public static List<JGitUtil.JGitPathInfo> listPathContent(org.eclipse.jgit.api.Git git, String branchName, String path)
Copyright © 2012–2017 JBoss by Red Hat. All rights reserved.