Package com.alphacsp.cit.exec

Examples of com.alphacsp.cit.exec.DefaultProcessLauncher.exec()


        DefaultProcessLauncher processLauncher = new DefaultProcessLauncher();
        Environment environment = executionContext.getEnvironment();
        processLauncher.setWorkingDir(environment.pwd().getAsFile());
        processLauncher.addCommands(commands);
        processLauncher.addEnvironmentVariables(environment.getVars());
        processLauncher.exec();
    }
}
View Full Code Here


        checkIntegrity(context);

        ProcessLauncher scriptLanucher = new DefaultProcessLauncher();
        scriptLanucher.addCommand("which");
        scriptLanucher.addCommand(getExecutableName());
        Process process = scriptLanucher.exec();
        String output = ProcessUtils.readOutput(process).trim();
        int exitCode = process.exitValue();
        if (exitCode != 0 || output.length() == 0) {
            throw new ValidationException("Executable " + getExecutableName() + " was not found!");
        }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.