[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2019-10-03 Thread camposaba...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 pau sabats commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 The error related with :  Cannot run program "nohup" means that it's searching for nohup.exe because is what jenkins requires when using 'sh' in the pipeline, so you can use nuhup.exe from here: "C:\Program Files\Git\usr\bin". Eventhough, what I have done in order to solve this issue is the following: Create a if else statement in your jenkinsfile that does:      if (isUnix()) --> sh "command"      else --> bat "command" doing so the pipeline running on agent windows will run as bat and this error no longer appears. Note: You can also use "tool config configuration" of jenkins and install tools from there. In case your sh commands were related with installation files        
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-issues/JIRA.169163.1458600265000.528.1570107300956%40Atlassian.JIRA.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2018-12-14 Thread etho...@inbox.lv (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 ethorsa edited a comment on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 {quote}I had to set the PATH System variable on the computer before I could get {{sh}} to work on Windows.{quote}That's important, it doesn't work otherwise. Adding it to {{PATH}} from within the pipeline (eg. {{withEnv(...)}} or  {{ environment \{ ... } }} ) doesn't work.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2018-12-14 Thread etho...@inbox.lv (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 ethorsa commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 

I had to set the PATH System variable on the computer before I could get sh to work on Windows.
 That's important, it doesn't work otherwise. Adding it to PATH from within the pipeline (eg. withEnv(...) or {{environment { ... }}}) doesn't work.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2018-04-29 Thread antony.gelb...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Antony Gelberg edited a comment on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 Happening here as well with Git Bash, sadly the workarounds didn't work for me at all even when I altered {{PATH}}:{code}pipeline {  environment {PATH = "C:\\Program Files\\Git\\usr\\bin;C:\\Program Files\\Git\\bin;${env.PATH}"  stages {stage('Sanity check') {  steps {sh 'script/code_scan.sh'  }}...{code}I did {{bat 'sh -c script/code_scan.sh } '} }  instead ,which seems to work but is ugly and might hide gremlins.Errors were of the form:{code}java.io.IOException: CreateProcess error=2, The system cannot find the file specified at java.lang.ProcessImpl.create(Native Method) at java.lang.ProcessImpl.(Unknown Source) at java.lang.ProcessImpl.start(Unknown Source)Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to windows-server-2012 (i-09233a1df87ee74c0)  at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1737)  at hudson.remoting.UserResponse.retrieve(UserRequest.java:313)  at hudson.remoting.Channel.call(Channel.java:952)  at hudson.Launcher$RemoteLauncher.launch(Launcher.java:1052)  at hudson.Launcher$ProcStarter.start(Launcher.java:449)  at org.jenkinsci.plugins.durabletask.BourneShellScript.launchWithCookie(BourneShellScript.java:186)  at org.jenkinsci.plugins.durabletask.FileMonitoringTask.launch(FileMonitoringTask.java:71)  at org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution.start(DurableTaskStep.java:176)  at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:229)  at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:153)  at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:108)  at sun.reflect.GeneratedMethodAccessor6254.invoke(Unknown Source)  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)  at java.lang.reflect.Method.invoke(Method.java:498)  at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93)  at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)  at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1213)  at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1022)  at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:42)  at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)  at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)  at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:157)  at org.kohsuke.groovy.sandbox.GroovyInterceptor.onMethodCall(GroovyInterceptor.java:23)  at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onMethodCall(SandboxInterceptor.java:133)  at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:155)  at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:159)  at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:129)  at com.cloudbees.groovy.cps.sandbox.SandboxInvoker.methodCall(SandboxInvoker.java:17)  at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:57)  at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:109)  at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:82)  at sun.reflect.GeneratedMethodAccessor198.invoke(Unknown Source)  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)  at java.lang.reflect.Method.invoke(Method.java:498)  at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImp

[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2018-04-29 Thread antony.gelb...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Antony Gelberg commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 Happening here as well with Git Bash, sadly the workarounds didn't work for me at all even when I altered  {PATH} : 

 

pipeline {
  environment {
PATH = "C:\\Program Files\\Git\\usr\\bin;C:\\Program Files\\Git\\bin;${env.PATH}"
  stages {
stage('Sanity check') {
  steps {
sh 'script/code_scan.sh'
  }
}
...
 

 I did  {bat 'sh -c script/code_scan.sh'}  instead ,which seems to work but is ugly and might hide gremlins. Errors were of the form: 

 

java.io.IOException: CreateProcess error=2, The system cannot find the file specified
	at java.lang.ProcessImpl.create(Native Method)
	at java.lang.ProcessImpl.(Unknown Source)
	at java.lang.ProcessImpl.start(Unknown Source)
Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to windows-server-2012 (i-09233a1df87ee74c0)
		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1737)
		at hudson.remoting.UserResponse.retrieve(UserRequest.java:313)
		at hudson.remoting.Channel.call(Channel.java:952)
		at hudson.Launcher$RemoteLauncher.launch(Launcher.java:1052)
		at hudson.Launcher$ProcStarter.start(Launcher.java:449)
		at org.jenkinsci.plugins.durabletask.BourneShellScript.launchWithCookie(BourneShellScript.java:186)
		at org.jenkinsci.plugins.durabletask.FileMonitoringTask.launch(FileMonitoringTask.java:71)
		at org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution.start(DurableTaskStep.java:176)
		at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:229)
		at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:153)
		at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:108)
		at sun.reflect.GeneratedMethodAccessor6254.invoke(Unknown Source)
		at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
		at java.lang.reflect.Method.invoke(Method.java:498)
		at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93)
		at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)
		at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1213)
		at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1022)
		at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:42)
		at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
		at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
		at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:157)
		at org.kohsuke.groovy.sandbox.GroovyInterceptor.onMethodCall(GroovyInterceptor.java:23)
		at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onMethodCall(SandboxInterceptor.java:133)
		at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:155)
		at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:159)
		at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:129)
		at com.cloudbees.groovy.cps.sandbox.SandboxInvoker.methodCall(SandboxInvoker.java:17)
		at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(Continuat

[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2018-04-29 Thread antony.gelb...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Antony Gelberg edited a comment on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 Happening here as well with Git Bash, sadly the workarounds didn't work for me at all even when I altered { { PATH} } :{code}pipeline {  environment {PATH = "C:\\Program Files\\Git\\usr\\bin;C:\\Program Files\\Git\\bin;${env.PATH}"  stages {stage('Sanity check') {  steps {sh 'script/code_scan.sh'  }}...{code}I did { { bat 'sh -c script/code_scan.sh } '} instead ,which seems to work but is ugly and might hide gremlins.Errors were of the form:{code}java.io.IOException: CreateProcess error=2, The system cannot find the file specified at java.lang.ProcessImpl.create(Native Method) at java.lang.ProcessImpl.(Unknown Source) at java.lang.ProcessImpl.start(Unknown Source)Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to windows-server-2012 (i-09233a1df87ee74c0)  at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1737)  at hudson.remoting.UserResponse.retrieve(UserRequest.java:313)  at hudson.remoting.Channel.call(Channel.java:952)  at hudson.Launcher$RemoteLauncher.launch(Launcher.java:1052)  at hudson.Launcher$ProcStarter.start(Launcher.java:449)  at org.jenkinsci.plugins.durabletask.BourneShellScript.launchWithCookie(BourneShellScript.java:186)  at org.jenkinsci.plugins.durabletask.FileMonitoringTask.launch(FileMonitoringTask.java:71)  at org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution.start(DurableTaskStep.java:176)  at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:229)  at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:153)  at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:108)  at sun.reflect.GeneratedMethodAccessor6254.invoke(Unknown Source)  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)  at java.lang.reflect.Method.invoke(Method.java:498)  at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93)  at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)  at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1213)  at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1022)  at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:42)  at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)  at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)  at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:157)  at org.kohsuke.groovy.sandbox.GroovyInterceptor.onMethodCall(GroovyInterceptor.java:23)  at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onMethodCall(SandboxInterceptor.java:133)  at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:155)  at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:159)  at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:129)  at com.cloudbees.groovy.cps.sandbox.SandboxInvoker.methodCall(SandboxInvoker.java:17)  at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:57)  at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:109)  at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:82)  at sun.reflect.GeneratedMethodAccessor198.invoke(Unknown Source)  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)  at java.lang.reflect.Method.invoke(Method.java:498)  at com.cloudbees.groovy.cps.impl.ContinuationPtr$Continuation

[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2018-03-23 Thread median...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Nick Jones edited a comment on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 With Git for Windows 2.16.2, I was able to add C:\Program Files\Git\usr\bin to the PATH (rather than C:\Program Files\Git\bin) and consequently my  `  {{ sh ` }}  commands work in both FreeStyle and Pipeline builds. No  `  {{ mklink ` }}  was necessary.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.3.0#73011-sha1:3c73d0e)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2018-03-23 Thread median...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Nick Jones commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 With Git for Windows 2.16.2, I was able to add C:\Program Files\Git\usr\bin to the PATH (rather than C:\Program Files\Git\bin) and consequently my `sh` commands work in both FreeStyle and Pipeline builds. No `mklink` was necessary.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.3.0#73011-sha1:3c73d0e)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2017-01-31 Thread tantann...@gmail.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Toshitaka Tandai commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 I Resolved this by arranging peschmae peschmae 's code above.try it 

 

mklink "C:\Program Files\Git\cmd\nohup.exe" "C:\Program Files\git\usr\bin\nohup.exe"
mklink "C:\Program Files\Git\cmd\msys-2.0.dll" "C:\Program Files\git\usr\bin\msys-2.0.dll"
mklink "C:\Program Files\Git\cmd\msys-iconv-2.dll" "C:\Program Files\git\usr\bin\msys-iconv-2.dll"
mklink "C:\Program Files\Git\cmd\msys-intl-8.dll" "C:\Program Files\git\usr\bin\msys-intl-8.dll"

 

 but I met https://issues.jenkins-ci.org/browse/JENKINS-38211 ...   
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-12-07 Thread freder...@staats.org (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Frederick Staats commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 I second the request to add WindowsCheck() on the line "if (!ws.act(new DarwinCheck()))  { // JENKINS-25848" in src/main/java/org/jenkinsci/plugins/durabletask/BourneShellScript.java If you add Git Bash to a Windows master or slave node in the default "System Path", but the Path that is used to run the Windows Service that runs Jenkins does not include "nohup.exe" you run into an error as Jenkins is hardwired to run "nohup" using the Windows Service path running Jenkins and not the path configured for of the Pipeline executor. My work around to run Git Bash in Jenkins on Windows in a Pipeline step is to add a "C:\Nohup" directory with just "nohup.exe" and supporting DLLs into the global Path that is used by the Windows service, as it is not an option to add all of Git executables to the system level Path. Here is an example of the error when sh.exe (Bash) is on the path but nohup.exe is not on the path on Windows: [C:\Jenkins\workspace\Multibranch_Pipeline_master-HJ66KBORTDATZ4DJ3RHNWWLARKMDIQIPNIY5RCIPMIMMK37I2FUQ] Running shell script [Pipeline] } [Pipeline] // node [Pipeline] } [Pipeline] // stage [Pipeline] End of Pipeline GitHub has been notified of this commit’s build result java.io.IOException: Cannot run program "nohup" (in directory "C:\Jenkins\workspace\Multibranch_Pipeline_master-HJ66KBORTDATZ4DJ3RHNWWLARKMDIQIPNIY5RCIPMIMMK37I2FUQ"): CreateProcess error=2, The system cannot find the file specified at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048) at hudson.Proc$LocalProc.(Proc.java:243) at hudson.Proc$LocalProc.(Proc.java:212) at hudson.Launcher$LocalLauncher.launch(Launcher.java:815) at hudson.Launcher$ProcStarter.start(Launcher.java:381) at org.jenkinsci.plugins.durabletask.BourneShellScript.launchWithCookie(BourneShellScript.java:147) at org.jenkinsci.plugins.durabletask.FileMonitoringTask.launch(FileMonitoringTask.java:61) at org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution.start(DurableTaskStep.java:158) at org.jenkinsci.plugins.workflow.cps.DSL.invokeStep(DSL.java:184) at org.jenkinsci.plugins.workflow.cps.DSL.invokeMethod(DSL.java:126) at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:108) at groovy.lang.GroovyObject$invokeMethod.call(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113) at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:151) at org.kohsuke.groovy.sandbox.GroovyInterceptor.onMethodCall(GroovyInterceptor.java:21) at org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onMethodCall(SandboxInterceptor.java:115) at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:149) at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:146) at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:123) at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:123) at com.cloudbees.groovy.cps.sandbox.SandboxInvoker.methodCall(SandboxInvoker.java:16) at BREDev.call(C:\Jenkins\jobs\ITSD BREDev Multibranch   
 

  
 
 
 
 

 
   

[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-11-29 Thread y...@shurup.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Yury Zaytsev commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 Please just add a new WindowsCheck() next to the DarwinCheck(), I'm also using sh step on Windows with sh from msys, and I don't have nohup. This only makes life difficult for poor Windows users :-/ Thank you!  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-08-02 Thread jgl...@cloudbees.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Jesse Glick updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-33708  
 
 
  Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
Change By: 
 Jesse Glick  
 
 
Component/s: 
 durable-task-plugin  
 
 
Component/s: 
 workflow-plugin  
 
 
Labels: 
 diagnostics testfest  windows workflow  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-08-02 Thread jgl...@cloudbees.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Jesse Glick updated an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-33708  
 
 
  Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
Change By: 
 Jesse Glick  
 
 
Labels: 
 diagnostics testfest  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-07-06 Thread 3...@gmx.ch (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 peschmae peschmae edited a comment on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 I got it working on my system with the shell from git-bash.# C:\Program Files\Git\bin is in the global search path, such that Jenkins finds _sh.exe_# Jenkins *also* needs _nohup.exe_ (as the error message suggests, see also [BourneshellScript.java|https://github.com/jenkinsci/durable-task-plugin/blob/master/src/main/java/org/jenkinsci/plugins/durabletask/BourneShellScript.java]). Git-bash has a _nohup.exe_ in /usr/bin. I just symlinked that (along with the shared libraries it needs)  int  into  /bin  by running from a Windows cmd shell :  {code:bash}mklink "C:\Program Files\Git\bin\nohup.exe" "C:\Program Files\git\usr\bin\nohup.exe"mklink "C:\Program Files\Git\bin\msys-2.0.dll" "C:\Program Files\git\usr\bin\msys-2.0.dll"mklink "C:\Program Files\Git\bin\msys-iconv-2.dll" "C:\Program Files\git\usr\bin\msys-iconv-2.dll"mklink "C:\Program Files\Git\bin\msys-intl-8.dll" "C:\Program Files\git\usr\bin\msys-intl-8.dll"{code}With that setup it's working just fine on my machines.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-07-06 Thread 3...@gmx.ch (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 peschmae peschmae edited a comment on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 I got it working on my system with the shell from git-bash.# C:\Program Files\Git\bin is in the global search path, such that Jenkins finds  sh  _sh . exe exe_ # Jenkins *also* needs  nohup  _nohup.exe_  (as the error message suggests , see also [BourneshellScript.java|https://github.com/jenkinsci/durable-task-plugin/blob/master/src/main/java/org/jenkinsci/plugins/durabletask/BourneShellScript.java] ). Git-bash has a  nohup  _nohup.exe_  in /usr/bin. I just symlinked that (along with the shared libraries it needs) int /bin:{code:bash}mklink "C:\Program Files\Git\bin\nohup.exe" "C:\Program Files\git\usr\bin\nohup.exe"mklink "C:\Program Files\Git\bin\msys-2.0.dll" "C:\Program Files\git\usr\bin\msys-2.0.dll"mklink "C:\Program Files\Git\bin\msys-iconv-2.dll" "C:\Program Files\git\usr\bin\msys-iconv-2.dll"mklink "C:\Program Files\Git\bin\msys-intl-8.dll" "C:\Program Files\git\usr\bin\msys-intl-8.dll"{code}With that setup it's working just fine on my machines.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-07-06 Thread 3...@gmx.ch (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 peschmae peschmae edited a comment on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 I got it working on my system with the shell from git-bash.# C:\Program Files\Git\bin is in the global search path, such that Jenkins finds _sh.exe_# Jenkins *also* needs _nohup.exe_ (as the error message suggests, see also [BourneshellScript.java|https://github.com/jenkinsci/durable-task-plugin/blob/master/src/main/java/org/jenkinsci/plugins/durabletask/BourneShellScript.java]). Git-bash has a _nohup.exe_ in /usr/bin. I just symlinked that (along with the shared libraries it needs) into /bin by running from a Windows cmd shell:{code: bash java }mklink "C:\Program Files\Git\bin\nohup.exe" "C:\Program Files\git\usr\bin\nohup.exe"mklink "C:\Program Files\Git\bin\msys-2.0.dll" "C:\Program Files\git\usr\bin\msys-2.0.dll"mklink "C:\Program Files\Git\bin\msys-iconv-2.dll" "C:\Program Files\git\usr\bin\msys-iconv-2.dll"mklink "C:\Program Files\Git\bin\msys-intl-8.dll" "C:\Program Files\git\usr\bin\msys-intl-8.dll"{code}With that setup it's working just fine on my machines.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-07-06 Thread 3...@gmx.ch (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 peschmae peschmae commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 I got it working on my system with the shell from git-bash. 
 
C:\Program Files\Git\bin is in the global search path, such that Jenkins finds sh.exe 
Jenkins also needs nohup (as the error message suggests). Git-bash has a nohup in /usr/bin. I just symlinked that (along with the shared libraries it needs) int /bin: 
 

 

Unable to find source-code formatter for language: bash. Available languages are: actionscript, html, java, _javascript_, none, sql, xhtml, xml


mklink "C:\Program Files\Git\bin\nohup.exe" "C:\Program Files\git\usr\bin\nohup.exe"
mklink "C:\Program Files\Git\bin\msys-2.0.dll" "C:\Program Files\git\usr\bin\msys-2.0.dll"
mklink "C:\Program Files\Git\bin\msys-iconv-2.dll" "C:\Program Files\git\usr\bin\msys-iconv-2.dll"
mklink "C:\Program Files\Git\bin\msys-intl-8.dll" "C:\Program Files\git\usr\bin\msys-intl-8.dll"
 

 With that setup it's working just fine on my machines.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 


[JIRA] (JENKINS-33708) Invocation of 'sh' on Windows should provide a more helpful error

2016-06-22 Thread docw...@gerf.org (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Christian Höltje commented on  JENKINS-33708  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Invocation of 'sh' on Windows should provide a more helpful error   
 

  
 
 
 
 

 
 Based on a normal FreeStyle job, I would expect `sh` to work the same. An example I would expect to work on Windows: 

 
sh('''#!c:\path\to\bash.exe

echo "I am in bash"
''')
 

  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.