title: How can I get SCP and ftp (from command line, not plugin) working within hudson
body: <p>I am running hudson CI server on a win32 machine.  After the build succeeds I want the exe created to be put on a public website.  The hudon plugins for SCP and ftp were not working the way I wanted (mostly because it chooses some odd directories for where to place them) so I made my own script for a command line scp that hudson calls.</p>
  
  <p>For some reason though when run under the hudson environment the scp bat file hangs.  It works fine when I call it from a command line though on the same machine.  </p>
  
  <p>Apparently this also fails when run from the task scheduler.  </p>
  
  <p>Can anyone think of a reason this would not work from a hudson or scheduler environment?</p>
  
  <pre><code>pscp.exe -batch -q -pw mypassword ..\..\installers\Output\myfilename  domain.com@domain.com:domains/domain.com/html/downloads
  </code></pre>
  
  <p>(Note that 'domain.com' is a replacement for my domain name...)</p>
  
  <p>Again, when I call that bat file from the command line it works just fine.</p>
  
  <p>Note also - the reason I call a bat file is because I replace the filename with a svn WCREV command - since hudson is brain dead and can't do that replacement in either the scp or ftp plugins or on the command line calls.  This method should work fin but it hangs.</p>
  
  <p><a href="http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html" rel="nofollow noreferrer">pscp is a command line ssh program associated with Putty</a>.  </p>
  
  <p>An additional issue I have is that this project access two svn repositories so hudson gets confused and can't provide the svn rev number at will in places where I expect it to be available.   (One repo is for third party things and the other is our code base)  We use the svn rev from our code base as part of the identifier to name the installer that is created.  </p>
  
  <p>I would be happy to use the ftp or scp from within hudson (The plugins) but they do not seem to work for me at all given the locations that hudson decides to put files (using build numbers - I do not want to use hudson's build numbers to identify builds - I prefer the svn revision) - thus I use the command line versions but those don't work either - they hang the hudson build process.  </p>