title: java.io.IOException: Batch scripts can only be run on Windows nodes ::: With jenkins - MacOSX
body: <p>I'm new with Jenkins and i want to execute commands using a node, but I have the following error:
  <strong><em>java.io.IOException: Batch scripts can only be run on Windows nodes.</em></strong></p>
  
  <p>My node is:</p>
  
  <pre><code>node ('master') {
    git 'https://github.com/bryaneibon/SeleniumWithCucucumber.git'
    bat label: '', script: 'mvn verify'
  }
  </code></pre>
  
  <p>When I delete the bash command, everything works perfectly.</p>
  
  <p>By trying with the command:</p>
  
  <pre><code>node ('master') {
    git 'https://github.com/bryaneibon/SeleniumWithCucucumber.git'
    bat 'mvn verify'
  }
  </code></pre>
  
  <p>I have exactly the same error.</p>
  
  <p><strong><em>The condensed log is as follows:</em></strong></p>
  
  <pre><code>No credentials specified
  &gt; /usr/local/bin/git rev-parse --is-inside-work-tree # timeout=10
  Fetching changes from the remote Git repository
  &gt; /usr/local/bin/git config remote.origin.url https://github.com/bryaneibon/SeleniumWithCucucumber.git 
  # timeout=10
  Fetching upstream changes from https://github.com/bryaneibon/SeleniumWithCucucumber.git
  &gt; /usr/local/bin/git --version # timeout=10
  &gt; /usr/local/bin/git fetch --tags --force --progress -- 
  .
  . 
  .
  [Pipeline] bat
  [Pipeline] }
  [Pipeline] // node
  [Pipeline] End of Pipeline
  java.io.IOException: Batch scripts can only be run on Windows nodes
  at org.jenkinsci.plugins.durabletask.WindowsBatchScript.doLaunch(WindowsBatchScript.java:58)
  at org.jenkinsci.plugins.durabletask.FileMonitoringTask.launchWithCookie(FileMonitoringTask.java:106)
  at org.jenkinsci.plugins.durabletask.FileMonitoringTask.launch(FileMonitoringTask.java:99)
  at org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution.start(DurableTaskStep.java:317)
  .
  .
  .
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
  at java.lang.Thread.run(Thread.java:745)
  Finished: FAILURE
  </code></pre>