Java Runtime command line Process
- by AEIOU
I have a class with the following code:
Process process = null;
try {
process = Runtime.getRuntime().exec("gs -version");
System.out.println(process.toString());
} catch (Exception e1) {
e1.printStackTrace();
} finally {
process.destroy();
}
I can run "gs -version"…