Hi, new to JIRA here.
I want to execute .bat file from local disk, as postfuction( 'run script' script runner)
please suggest if i can execute .bat file?
tried this: def proc = "c:\\users\\40013750\\test.bat".execute();
g.codehaus.groovy.runtime.InvokerInvocationException: java.io.IOException: Cannot run program "c:\users\40013750\test.bat": error=2, No such file or directory at ConsoleScriptExecution1_groovyProxy.run(Unknown Source) Caused by: java.io.IOException: Cannot run program "c:\users\40013750\test.bat": error=2, No such file or directory at Script1.run(Script1.groovy:1) at Script1$run.call(Unknown Source) at Script1$run.call(Unknown Source) at com.adaptavist.sr.cloud.workflow.AbstractScript.evaluate(AbstractScript.groovy:33) at com.adaptavist.sr.cloud.events.ScriptExecution.run(ScriptExecution.groovy:29) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at ConsoleScriptExecution1_groovyProxy.run(Unknown Source) at com.adaptavist.sr.cloud.MainHandler.executeScript(MainHandler.groovy:388) at com.adaptavist.sr.cloud.MainHandler.processInput(MainHandler.groovy:334) at com.adaptavist.sr.cloud.MainHandler.access$0(MainHandler.groovy) at com.adaptavist.sr.cloud.MainHandler$_handleRequest_closure1.doCall(MainHandler.groovy:154) at com.adaptavist.sr.cloud.MainHandler$_handleRequest_closure1.call(MainHandler.groovy) Caused by: java.io.IOException: error=2, No such file or directory ... 14 more
I think you need to use the following format
def urbatname = new File(c:\\users\\40013750\\test.bat).absolutePath
below you can find more detail about the fix
Thank you!, But it's given the path of file, but did not open .bat from cmd...
is there something that i need to do to integrate between cmd and jira to execute this .bat file (before this line - def urbatname = new File(c:\\users\\40013750\\test.bat).absolutePath )?
Calling all Confluence Cloud Admins! We created a new Community Group to support your unique needs as Confluence admins. This is a group where you can ask questions, access resou...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events