Topic "Can't launch PuTTY in ConEmu anymore (wrong position of "-load" argument?)"

Author Message
CherryDT
[View user's profile]

Joined: 2016-12-15
Posts: 3
Hello,

I am launching PuTTY inside ConEmu. To achieve this, my PuTTY application path is set to:

Code:
"c:\Program Files\conemu\ConEmu64.exe" /cmd "C:\Program Files (x86)\PuTTY\putty.exe"


This worked perfectly for a long time. I was last using version 5.5.6 (build 4746). Then I updated to version 5.9.3 (build 7136) and it stopped working.

I get the following error:

Code:
---------------------------
ConEmu 161206 [64]
---------------------------
Unknown switch specified:



-load "WinSCP temporary session" /cmd "C:\Program Files (x86)\PuTTY\putty.exe"



Visit website to get thorough switches description:

https://conemu.github.io/en/ConEmuArgs.html



Or run ‘ConEmu.exe -?’ to get the brief.
---------------------------
OK   
---------------------------


Apparently, WinSCP now injects the "-load" argument between application path and the first parameter I define (which would be "/cmd") and hence breaks the command line. I haven't found any way to change this. Am I doing something wrong? It would be great if the "-load ...." argument would just be another pattern, e.g. "!L", so I could put it where it belongs...

Thanks!

PS: I'm running Windows 10 Pro Build 14393.576
Advertisements
Makc666
[View user's profile]

Joined: 2016-12-08
Posts: 52
Location: MSK-RU
The only thing about -load I was able to find in docs is here:
https://winscp.net/eng/docs/ui_pref_integration_app
Code:
If pattern !@ is not used, parameter -load <site> is automatically added to the command.

+
https://the.earth.li/~sgtatham/putty/latest/htmldoc/Chapter3.html#using-cmdline
Code:
In order to start an existing saved session called sessionname, use the -load option (described in section 3.8.3.1).

+
https://the.earth.li/~sgtatham/putty/latest/htmldoc/Chapter3.html#using-cmdline-load
CherryDT
[View user's profile]

Joined: 2016-12-15
Posts: 3
Well, I don't want to use !@, !U, !P because I am using private keys which should be set correctly, also I don't want to do a hack like using !@ but in some ignored parameter or so and then manually adding '-load "WinSCP Temporary Session"' because WinSCP selects existing sessions if possible, so it wouldn't always be hardcoded to "WinSCP Temporary Session"...

It looks like in the past, the -load was appended at the end of the command, which works great for such a scenario (albeit less flexible than with a dedicated pattern), but in the current version it's inserted at the beginning of the command line after the application name, which breaks ConEmu or any other "prefixed" command like this...
Makc666
[View user's profile]

Joined: 2016-12-08
Posts: 52
Location: MSK-RU
CherryDT wrote:
Well, I don't want to use !@, !U, !P because ...


And this one?

https://conemu.github.io/en/NewConsole.html

Quote:
Or, from your shell prompt (e.g. cmd.exe started in ConEmu) you can start PuTTY (or any other simple GUI applications) in the new ConEmu tab (or split):
Code:
PuTTY.exe -new_console -load "yourserver"


P.S. Can you tell me, how do you execute ConEmu64.exe?

When you say that you start:
Code:
"c:\Program Files\conemu\ConEmu64.exe" /cmd "C:\Program Files (x86)\PuTTY\putty.exe"

it sounds like you start it from the .bat file.

In that case I hardly believe that it then changes to:
"c:\Program Files\conemu\ConEmu64.exe" -load "WinSCP temporary session" /cmd "C:\Program Files (x86)\PuTTY\putty.exe"
somewhere.

I don't see WinSCP involved anywhere?!
CherryDT
[View user's profile]

Joined: 2016-12-15
Posts: 3
I am talking about setting it as path in WinSCP for PuTTY (similar to how the WinSCP docs suggest running WSL SSH instead). Under "Applications" in the settings.

About -new_console: It's a ConEmu-interpreted parameter to start a command in a new console, so it works when run from a shell which runs inside ConEmu already... Chicken and egg issue: WinSCP is not running in ConEmu Wink

And it does change:


martin◆
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26730
Location: Prague, Czechia
Thanks for your report. I'll try to find some good solution.
martin◆
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26730
Location: Prague, Czechia
This issue has been added to the tracker:
https://winscp.net/tracker/show_bug.cgi?id=1493

I'm sending you an email with a development version of WinSCP to the address you have used to register on this forum.
Advertisements

You can post new topics in this forum

Search

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License