scp

netbeans - scp after build

Hi I'd like to copy a file to a remote server with scp after building, using Netbeans. What I do now manually is: Clean and Build Main Project scp dist/project.jar login@dest/...../...... Is there some way to automate this task? I tried looking at the build.xml file, but it really looks like something I don't want to mess with. Th...

scp-ing without replacing folder

How do I scp an entire folder into a folder of the same name without replacing the content in the destination folder? (instead, I would like to add to the contents of the destination folder) ...

How to respond to password prompt when using SCP in a shell script?

First of all, I am well aware of that there are many of questions regarding this topic. I have read them, but still could figure out an appropriate answer for my situation. I would like to scp the entire ~/cs###/assign1 dir from local to school home dir with a shell script. My question is, is there a way in my script to wait for the pas...

scp on WebClient class in .Net

I have a project already written using .Net's WebClient class. It works great for FTP and WebDAV resources, but how can I get it to work with SCP or SFTP? ...

cURL php extension for windows with SCP and SFTP support

I switched over to zendserver(VS8 php(5.3) binaries), and now curl(7.19.4) seems to be lacking SCP and SFTP protocol support(verified by errors and phpinfo). Curl itself is installed correctly, it's just lacking the protocol support mentioned. This worked out of the box on the VC9(thread safe) binaries I downloaded off php.net(this ins...

Using Ruby and SCP/SSH, how to determine if a file exists before uploading a copy

I'm uploading a file to a remote server using SCP, but what's the proper way of seeing if that file exists before doing so? ...

Moving a git repo to another server

I have a git clone/repo on a development server, but I am now moving to another one. I don't want to commit all my local branches and changes to the main repository, so how can I make an exact copy of everything on oldserver to newserver? I tried oldserver:~$ scp -rp project newserver:~/project but then I just get loads and loads of "t...

How do I ensure that a username/password combination is not read from memory

How do I ensure that a username/password combination is not read from memory while my application is in use. My program is a GUI wrapper for some CYGWIN tools, including SSH and SCP. I need to ensure single sign-on capabilities to a variety of hosts. ...

Scp locate's output by Xargs

I want to make a list of files of locate's output. I want scp to take the list. I am not sure about the syntax. My attempt with pseudo-code locate labra | xargs scp {} [email protected]:~/Desktop/ How can you move the files to the destination? ...

Periodically backup files to another server via scp

There are set of log files that have a pattern xxxxxYYY where xxxx -> some text and YYY is a sequence number increasing sequentially by one and wrapping around. Only the last n number of files are available at a given time. I would like to write a foolproof script that would make sure that all the log files are backed up in another serv...

Ruby Sinatra - Add custom routes for files in Public folders.

Hi, I've a Sinatra app which would be used by different clients. I wish to show the client's Company Logo and a custom layout.erb for each client. The code base is essentially same for everyone. All I need is a way to easily maintain a different set of files in the 'Public' directory and 'layout.erb', and when deploying to the remote ...

scp with short password

when i tried to create public private key pair for password which length is less then 4 it does accept my password because of length is it any option to use scp with short length passwords ...

Deploy to remote server using scp in NANT script

I am trying to copy a file to a remote server using scp task in Nant.Contrib . I have used the following code to do that: <target name= "QADeploy"description="gthtyb" > <loadtasks assembly="C:\nantcontrib-0.85\bin\NAnt.Contrib.Tasks.dll" /> <echo message="htyh"/> <scp file="D:\SourceTest\redist.txt" server="\\10.4.30.19" user="xxx:uuuu...

SVN or SCP creating .tmp files

So we have two automated processes on our build system. The first performs an svn export which exports a project to directory A. The second performs an scp which scps a project from directory A to a different machine. Sometimes, possibly due to a race condition, a situation arises in which a whole bunch of .tmp files are created, almo...

Cannot SCP a path with spaces from bash script?

I have a bash script which generates an SCP command to execute. The relevant parts of the code look like this: echo $COPY_CMD $COPY_CMD My output looks like this: rascher@localhost:~/Desktop/video_final$ ./xfervids.sh scp "/media/My Book/PhotosVideos/Videos/18May2008Download/SD_VIDEO/PRG001/MOV056.MOD" [email protected]:./video...

Net::SCP / Net::SCP::Expect - how to deal with password vs key authentication

I have a script that works on different clients, and need to SCP files to different hosts. Depending on the combination of client & server, I may need to use password authentication or public key authentication. I cannot really know in advance which one to use. There are 2 CPAN libraries for SCP that I use: Net::SCP: works with public...

how to perform ssh and scp equivalent function in python code

I want to login in different machine in the network and copy a file from that machine to my machine.I want to do this using python.Any idea how can i do this .I have python 2.5 a nd ubuntu 8.10 ...

How to prevent wild card glob expansion for occurring for my command like scp does?

I wish for my application to accept an file specification argument literally, without wildcard expansion. This is because the directory from which my command is being run is not the directory (or machine) where the glob expansion should be performed. I believe the scp somehow manages to do this, but I am at a loss to replicate that in ...

Ant scp task not working, even with jsch on ant/lib

I need to copy a war file via scp. I have added the jsch-0.1.42.jar to $ANT_HOME/lib but I'm still getting this error: Cause: the class org.apache.tools.ant.taskdefs.optional.ssh.Scp was not found. This looks like one of Ant's optional components. This is the result of running ant -diagnostics just in case: http://...

Using a filename with spaces with scp and chmod in bash

Periodically, I like to put files in the /tmp directory of my webserver to share out. What is annoying is that I must set the permissions whenever I scp the files. Following the advice from another question I've written a script which copies the file over, sets the permissions and then prints the URL: #!/bin/bash scp "$1" SERVER:"/var/...