Use WinSCP to download multiple files from SFTP server on custom port?

Advertisement

BenBrown
Guest

Use WinSCP to download multiple files from SFTP server on custom port?

Hi all! I've been trying to find an existing script or automation solution for this task, and StackExchange has several cool answers from Martin Prikryl – so I thought to ask directly here instead:

What I have:
  • SFTP server with custom port,
  • login+password,
  • exact path and filename pattern for the bits I want to download.
What I want:
  • A Windows shell script that can be run weekly to log into that SFTP server and retrieve files that match the filename pattern.
Before I spend lots of time trying to build such a script myself, perhaps you've already used something like this and can point me in the right direction?

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,441
Location:
Prague, Czechia

Re: Use WinSCP to download multiple files from SFTP server on custom port?

There's nothing special about your task. It's just a simple download script.
Start here:

For the custom port, just add :port to the session URL in the open command:
open sftp://user:pass@host:port/

Reply with quote

Advertisement

You can post new topics in this forum