Skip to content

Instantly share code, notes, and snippets.

@lucacesari
Created September 14, 2014 15:00
Show Gist options
  • Save lucacesari/542615a4a241ac630544 to your computer and use it in GitHub Desktop.
Save lucacesari/542615a4a241ac630544 to your computer and use it in GitHub Desktop.
Call external process in Java7
ProcessBuilder builder = new ProcessBuilder();
builder.command("command1");
builder.inheritIO(); // if you need to see the sysout and syserr
Process p = builder.start();
p.waitFor()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment