private Process executeToAstProcess ( String argument ) throws IOException { try { Process p = new ProcessBuilder ( "python" , codeGenBinDirectory + "/jp-to-ast.py" , argument ) . start ( ) ; p . waitFor ( ) ; return p ; } catch ( InterruptedException e ) { Thread . currentThread ( ) . interrupt ( ) ; throw new RuntimeException ( e ) ; } }
Execute the jp - to - ast . py command and wait for it to complete .