org.jenkinsci.plugins.managedscripts
Class ScriptBuildStep
java.lang.Object
hudson.tasks.BuildStepCompatibilityLayer
hudson.tasks.Builder
org.jenkinsci.plugins.managedscripts.ScriptBuildStep
- All Implemented Interfaces:
- hudson.ExtensionPoint, hudson.model.Describable<hudson.tasks.Builder>, hudson.tasks.BuildStep
public class ScriptBuildStep
- extends hudson.tasks.Builder
LibraryBuildStep Builder.
A project that uses this builder can choose a build step from a list of predefined config files that are uses as command line scripts. The hash-bang sequence at the beginning of each file is used
to determine the interpreter.
- Author:
- Norman Baumann, Dominik Bartholdi (imod)
| Nested classes/interfaces inherited from interface hudson.tasks.BuildStep |
hudson.tasks.BuildStep.PublisherList |
| Nested classes/interfaces inherited from interface hudson.ExtensionPoint |
hudson.ExtensionPoint.LegacyInstancesAreScopedToHudson |
| Fields inherited from interface hudson.tasks.BuildStep |
BUILDERS, PUBLISHERS |
| Methods inherited from class hudson.tasks.Builder |
all, getRequiredMonitorService, prebuild |
| Methods inherited from class hudson.tasks.BuildStepCompatibilityLayer |
getProjectAction, getProjectAction, getProjectActions, perform, prebuild |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface hudson.tasks.BuildStep |
getProjectAction, getProjectActions, prebuild |
ScriptBuildStep
@DataBoundConstructor
public ScriptBuildStep(String buildStepId,
String[] buildStepArgs)
- The constructor
- Parameters:
buildStepId - the Id of the config filebuildStepArgs - list of arguments specified as buildStepargs
getBuildStepId
public String getBuildStepId()
getBuildStepArgs
public String[] getBuildStepArgs()
perform
public boolean perform(hudson.model.AbstractBuild<?,?> build,
hudson.Launcher launcher,
hudson.model.BuildListener listener)
- Perform the build step on the execution host.
Generates a temporary file and copies the content of the predefined config file (by using the buildStepId) into it. It then copies this file into the workspace directory of the execution host
and executes it.
- Specified by:
perform in interface hudson.tasks.BuildStep- Overrides:
perform in class hudson.tasks.BuildStepCompatibilityLayer
getDescriptor
public ScriptBuildStep.DescriptorImpl getDescriptor()
- Specified by:
getDescriptor in interface hudson.model.Describable<hudson.tasks.Builder>- Overrides:
getDescriptor in class hudson.tasks.Builder
Copyright © 2004-2012. All Rights Reserved.