title: SCP from Windows to Linux using Jenkins pipeline script
body: <p>I want to do <code>SCP</code> from Windows Jenkins node to Linux server. In this set up, Windows machine is a Jenkins slave and the target server where i want to copy is Linux.</p>
  
  <p>Below is my Jenkins pipeline script. Before the below script runs, i am cloning the repository and then building the project which finally creates a <code>.jar</code> file. I want to copy this file to Linux server.</p>
  
  <pre><code>stage('SCP JAR file') {
      steps {
               bat 'scp /c/Jenkins/workspace/migration/test-project/build/libs/ssupservice-0.0.1-SNAPSHOT.jar rxp096p@server:/home/rxp096p/testing'
            }
       }
  }
  </code></pre>
  
  <p>My working directory is <code>/c/Jenkins/workspace/migration/test-project/</code>. Inside the given directory, <code>build/libs</code> folder gets created where the required <code>.jar</code> file is present.</p>
  
  <p>Running above script gives the following error:</p>
  
  <pre><code>/c/Jenkins/workspace/migration/test-project/build/libs/ssupservice-0.0.1-SNAPSHOT.jar: No such file or directory
  </code></pre>