batch file to open multiple txt files within WinSCP ?/

Advertisement

cvj
Joined:
Posts:
5

batch file to open multiple txt files within WinSCP ?/

I use winscp on my lynux server to view and edit multiple text files using the internal editor..

what I would like to know is :- can I make some sort of batch file that will open multiple files to save me having to open all the files one at a time

thanks

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
34,115
Location:
Prague, Czechia

Re: batch file to open multiple txt files within WinSCP ?/

Well, you can generate the URL. But in this case, I believe it's better to refer to your saved site on the command-line, to avoid duplicating the login info:
"C:\Program Files (x86)\WinSCP\WinSCP.exe" "site_name" /edit /remote/path/file.txt

Reply with quote

cvj
Joined:
Posts:
5

Re: batch file to open multiple txt files within WinSCP ?/

Yeah thanks ,,
So can I do open multiple files on one line tho ?

"F:\WinSCP\WinSCP.exe" "BR" /edit /home/autoconfig.json config.json

Reply with quote

Advertisement

cvj

Re: batch file to open multiple txt files within WinSCP ?/

yeah that I have seen and does help but I have to log in to server every time I start new instance/file tho,,,

is there no way this type of command can be executed from within WinSCP rather than from windows command prompt ?

Reply with quote

cvj
Joined:
Posts:
5

Re: batch file to open multiple txt files within WinSCP ?/

martin wrote:

You can use Shift+F4 and type (or rather paste or later select from the history) a semicolon-separated list of the files you want to edit.

See https://winscp.net/eng/docs/task_edit


ok now this I did already try tho. I can open each file as just one but both together ,, no


@echo off
"F:\WinSCP\WinSCP.exe" "BR" /edit /home/autoconfig.json; /home/config.js

Reply with quote

Advertisement

You can post new topics in this forum