Class NVMUtilities
- java.lang.Object
-
- io.interrogate.npmyarnwrappersteps.plugin.NVMUtilities
-
public class NVMUtilities extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
NVMUtilities.NodeExecutor
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DEFAULT_NODEJS_VERSION
static java.lang.String
DEFAULT_NPM_REGISTRY
-
Constructor Summary
Constructors Constructor Description NVMUtilities()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static hudson.util.ArgumentListBuilder
getCommand(java.lang.String command, boolean isInstallFromNVMRC, NVMUtilities.NodeExecutor nodeExecutor)
static hudson.util.ArgumentListBuilder
getCommand(java.lang.String command, java.lang.String nodeJSVersion, NVMUtilities.NodeExecutor nodeExecutor)
static hudson.util.ArgumentListBuilder
getNPMCommand(java.lang.String command, boolean isInstallFromNVMRC)
static hudson.FilePath
getTargetDirectory(hudson.FilePath workspace, java.lang.String workspaceSubdirectory)
static hudson.util.ArgumentListBuilder
getYarnCommand(java.lang.String command, boolean isInstallFromNVMRC)
static void
install(hudson.FilePath workspace, hudson.Launcher launcher, hudson.model.TaskListener listener)
static void
install(hudson.FilePath workspace, hudson.Launcher launcher, hudson.model.TaskListener listener, java.lang.String nvmInstallerUrl)
static boolean
isInstallFromNVMRC(hudson.FilePath workspace, java.lang.String workspaceSubdirectory)
static void
setNPMConfig(java.lang.String key, java.lang.String value, java.lang.String workspaceSubdirectory, hudson.FilePath workspace, hudson.Launcher launcher, java.io.PrintStream logger, hudson.EnvVars envVars)
static void
setNVMHomeEnvironmentVariable(hudson.EnvVars envVars)
static void
setNVMHomeEnvironmentVariable(hudson.EnvVars envVars, jenkins.tasks.SimpleBuildWrapper.Context context)
-
-
-
Field Detail
-
DEFAULT_NPM_REGISTRY
public static final java.lang.String DEFAULT_NPM_REGISTRY
- See Also:
- Constant Field Values
-
DEFAULT_NODEJS_VERSION
public static final java.lang.String DEFAULT_NODEJS_VERSION
- See Also:
- Constant Field Values
-
-
Method Detail
-
install
public static void install(hudson.FilePath workspace, hudson.Launcher launcher, hudson.model.TaskListener listener, java.lang.String nvmInstallerUrl) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
install
public static void install(hudson.FilePath workspace, hudson.Launcher launcher, hudson.model.TaskListener listener) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
setNVMHomeEnvironmentVariable
public static void setNVMHomeEnvironmentVariable(hudson.EnvVars envVars)
-
setNVMHomeEnvironmentVariable
public static void setNVMHomeEnvironmentVariable(hudson.EnvVars envVars, jenkins.tasks.SimpleBuildWrapper.Context context)
-
getCommand
public static hudson.util.ArgumentListBuilder getCommand(java.lang.String command, java.lang.String nodeJSVersion, NVMUtilities.NodeExecutor nodeExecutor)
-
isInstallFromNVMRC
public static boolean isInstallFromNVMRC(hudson.FilePath workspace, java.lang.String workspaceSubdirectory) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
getCommand
public static hudson.util.ArgumentListBuilder getCommand(java.lang.String command, boolean isInstallFromNVMRC, NVMUtilities.NodeExecutor nodeExecutor)
-
getNPMCommand
public static hudson.util.ArgumentListBuilder getNPMCommand(java.lang.String command, boolean isInstallFromNVMRC)
-
getYarnCommand
public static hudson.util.ArgumentListBuilder getYarnCommand(java.lang.String command, boolean isInstallFromNVMRC)
-
setNPMConfig
public static void setNPMConfig(java.lang.String key, java.lang.String value, java.lang.String workspaceSubdirectory, hudson.FilePath workspace, hudson.Launcher launcher, java.io.PrintStream logger, hudson.EnvVars envVars) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
getTargetDirectory
public static hudson.FilePath getTargetDirectory(hudson.FilePath workspace, java.lang.String workspaceSubdirectory) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
-