Showing posts with label runtime. Show all posts
Showing posts with label runtime. Show all posts

Wednesday, July 16, 2014

Executing windows commands through java

I wanted to start the node server programmatically.
>node app.js


Using Java:

String executePath = "cmd /c start node app.js"

Runtime.getRuntime().exec(executePath);