-1

I want to copy all files with extension *out to my local machine form my account keeping the same tree path of each file my trail is

scp --parents -r   @remote:~/path/*out ./

such trail doesn't work

1 Answers1

1

rsync is a little more dependable.

https://unix.stackexchange.com/questions/193368/can-scp-create-a-directory-if-it-doesnt-exist

It does recursion and creates directories galore. scp is capable of all these things too which I think you are already doing it. But if the parent directories don't exist on the local machine you just have to use the necessary parameters in scp to do that.