Putty relative path not working. Must load from WinSCP starting directory.
I have experienced a slight issue with how WinSCP loads putty.
I have WinSCP loaded via bat file.
calls
It seems that the putty integration does not recognize a relative path when putty is in a different directory to the starting command. So unless it is in the same directory as the bat file it cannot work without setting a full path.
If i cd into the folder first using the bat file, then call do start it works as intended.
So this bat file only works if putty is in the same location as the bat file.
Whereas this bat file only works if putty in the same directory as WinSCP.
Is this a bug or something intentional i don't fully understand? I'd like to be able to set a relative path to putty regardless of where WinSCP was started.
I have WinSCP loaded via bat file.
loadme.bat
start bin\WinSCP.exe
It seems that the putty integration does not recognize a relative path when putty is in a different directory to the starting command. So unless it is in the same directory as the bat file it cannot work without setting a full path.
If i cd into the folder first using the bat file, then call do start
WinSCP.exe
So this bat file only works if putty is in the same location as the bat file.
start bin\WinSCP.exe & for %%f in (%cd%\keys\*.ppk) do start bin\kageant.exe "%%f" exit
Whereas this bat file only works if putty in the same directory as WinSCP.
cd %cd%\bin start WinSCP.exe & for %%f in (%cd%\..\keys\*.ppk) do start kageant.exe "%%f" exit
Is this a bug or something intentional i don't fully understand? I'd like to be able to set a relative path to putty regardless of where WinSCP was started.