Class CommandInterperterCondition
java.lang.Object
org.jenkins_ci.plugins.run_condition.RunCondition
org.jenkins_ci.plugins.run_condition.common.AlwaysPrebuildRunCondition
org.jenkins_ci.plugins.run_condition.contributed.CommandInterperterCondition
- All Implemented Interfaces:
ExtensionPoint
,Describable<RunCondition>
- Direct Known Subclasses:
BatchFileCondition
,ShellCondition
Common part between
ShellCondition
and BatchFileCondition
.- Author:
- Chris Johnson
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jenkins_ci.plugins.run_condition.RunCondition
RunCondition.RunConditionDescriptor
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract String[]
buildCommandLine
(FilePath script) createScriptFile
(FilePath dir) Creates a script file in a temporary name in the specified directory.final String
protected abstract String
protected abstract String
boolean
runPerform
(AbstractBuild<?, ?> build, BuildListener listener) Decide whether to run the perform method in the BuildStep.Methods inherited from class org.jenkins_ci.plugins.run_condition.common.AlwaysPrebuildRunCondition
runPrebuild
Methods inherited from class org.jenkins_ci.plugins.run_condition.RunCondition
all, getDescriptor
-
Field Details
-
command
Command to execute. The format depends on the actualCommandInterperterCondition
implementation.
-
-
Constructor Details
-
CommandInterperterCondition
-
-
Method Details
-
getCommand
-
runPerform
public boolean runPerform(AbstractBuild<?, ?> build, BuildListener listener) throws InterruptedExceptionDescription copied from class:RunCondition
Decide whether to run the perform method in the BuildStep.- Specified by:
runPerform
in classRunCondition
- Returns:
- true if the perform method of the BuildStep should run
- Throws:
InterruptedException
-
createScriptFile
Creates a script file in a temporary name in the specified directory.- Throws:
IOException
InterruptedException
-
buildCommandLine
-
getContents
-
getFileExtension
-