Klasse GitRepositoryValidator
java.lang.Object
io.jenkins.plugins.forensics.git.util.GitRepositoryValidator
Inspects a given working tree and determines if this path is a valid Git repository that can be used to run one of
the forensics analyzers.
- Autor:
- Ullrich Hafner
-
Feldübersicht
-
Konstruktorübersicht
KonstruktorBeschreibungGitRepositoryValidator
(SCM scm, Run<?, ?> build, FilePath workTree, TaskListener listener, edu.hm.hafner.util.FilteredLog logger) Creates a newGitRepositoryValidator
. -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungorg.jenkinsci.plugins.gitclient.GitClient
Creates aGitClient
using the field values.getHead()
Returns the GIT_COMMIT environment variable, or 'HEAD' if not set.getId()
Returns the key for the associated SCM.getScm()
Returns the associated SCM.boolean
Returns whether the specified working tree contains a valid Git repository that can be used to run one of the forensics analyzers.
-
Felddetails
-
INFO_SHALLOW_CLONE
Error message.- Siehe auch:
-
-
Konstruktordetails
-
GitRepositoryValidator
public GitRepositoryValidator(SCM scm, Run<?, ?> build, FilePath workTree, TaskListener listener, edu.hm.hafner.util.FilteredLog logger) Creates a newGitRepositoryValidator
.- Parameter:
scm
- theSCM
to create the blamer forbuild
- the current buildworkTree
- the working tree to inspectlistener
- a task listenerlogger
- a logger to report error messages
-
-
Methodendetails
-
isGitRepository
public boolean isGitRepository()Returns whether the specified working tree contains a valid Git repository that can be used to run one of the forensics analyzers.- Gibt zurück:
true
if the working tree contains a valid repository,false
otherwise
-
createClient
public org.jenkinsci.plugins.gitclient.GitClient createClient()Creates aGitClient
using the field values.- Gibt zurück:
- a
GitClient
-
getHead
Returns the GIT_COMMIT environment variable, or 'HEAD' if not set.- Gibt zurück:
- a
GitClient
-
getId
Returns the key for the associated SCM.- Gibt zurück:
- the SCM key
-
getScm
Returns the associated SCM.- Gibt zurück:
- the SCM
-