How-To: Pull a Directory With SCP

Just a quickie (and the first post in a series of How-To’s)… I’m sure many of you know the syntax for this but since I only ever used SCP and PSCP to push files, pulling them was a bit new for me. Anyway, a co-worker (thanks Tony!) gave me a hand with this and I thought it might be useful to others. So, here it is:

$ scp -r username@host:path/to/your/directory localnameofdirectory

You can substitute the ‘localnameofdirectory’ with a ‘.’ if you want to use the name that already exists on the host. Also, for the sake of delineation of the command.. the ‘-r’ flag is optional and instructs SCP to recursively copy.

HTH!

About John Pencola

Hello, my name is John Pencola. I can't get enough of exploring new technologies, discussing software principals, creating programs and having fun with interface design. I will share my experiences here and hope Liquid Language adds some useful information to the vast sea that is the web.
This entry was posted in How-To and tagged , , , . Bookmark the permalink.