return execute(file, directory, args, null, null);
}
public Integer execute(String file, File directory, String args[], Runnable preRun, Runnable postRun) {
ExternalProcessBuilder processBuilder = new ExternalProcessBuilder(directory.getAbsolutePath() + "/" + file);
processBuilder = processBuilder.workingDirectory(directory);
if (args != null) {
for (String arg : args) {
processBuilder = processBuilder.addArgument(arg);
}
}