Web lists-archives.com

Re: [ANNOUNCEMENT] Updated: mintty 2.9.5




Hello Andrey,

On 10.12.2018 14:08, Andrey Repin wrote:
Greetings, Thomas Wolff!

BTW, Cygwin itself does it differently. %Cygwin%\bin is converted to /usr/bin.
This setup should be handled in the Posix path domain.
Give me a good reason why should you second-guess Cygwin's own functionality?
You have apparently set up some cmd scripts as mintty user commands, so
you're thinking in Windows terms here.
One is very distantly related to another.
I set up programs to work as user commands, it's not actually relevant, if
they are cmd scripts, or perl, both, or neither.
Acknowledged.

However, the idea is more to use cygwin tools for such purposes. In either
case, the path is handled within a cygwin session (mintty) and cygwin does
the conversion both ways, so it should be fine for you.
The path is handled within a **cygwin** session, but mintty is not it.
Sure mintty is a cygwin program, linked with cygwin and thus starting a cygwin session.

And you don't have to second-guess cygwin behavior, if you do it the way I
propose. And you would be safe if behavior would one day change (though I do
not foresee it in this case).
I'm not tampering with cygwin behaviour in any way, just changing PATH, so that a tool subsequently invoked by `popen` can use it.

P.S.
I've tried to do it "your way" for tests.
Had enough of an issue starting Cygwin itself and rolled it back.
Cygwin already quite capable of path conversion, no need to deny it this ability.
Not sure whether you're having a problem with your mintty command scripts. I've tested this thoroughly, everything works fine in these configuration combinations, with a test script D:\bin\test.cmd that echoes %MINTTY_SELECT% attached to keyboard shortcut Ctrl+Shift+t:

KeyFunctions=t:`test.cmd`
UserCommandsPath=D:\bin:%s

KeyFunctions=t:`test.cmd`
UserCommandsPath=/cygdrive/d/bin:%s

KeyFunctions=t:`D:/bin/test.cmd`
#UserCommandsPath=

KeyFunctions=t:`/cygdrive/d/bin/test.cmd`
#UserCommandsPath=

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple