This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def nullAppender = [ append : {a,b=null,c=null -> }] as Appendable | |
(1..10).collect { | |
def prog="touch ${it}.X".execute() | |
prog.consumeProcessOutput(nullAppender,nullAppender) | |
return prog | |
}.each { it.waitFor() } |
I just used touch as a simple illustration, replace it with whatever you need. If you want to execute your process in anotehr directory than the current worknig directory or want to customise the environment, remember that execute can take two parameters to do exactly that.
No comments:
Post a Comment