This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [ANNOUNCEMENT] Updated: mintty-0.5.1-1

2009/10/17 Eric Backus:
> In passing, I'll note that xterm on my very old and out-of-date SuSE linux
> installation uses DEL, so matches your new version of mintty

Yeah, I think the GNU people managed to browbeat Linux distros into
standardising on ^? some time ago.

>> The workaround is to stick the following somewhere in your startup files:
>> echo $'\e[?67h'
>> stty erase '^H'
> Sure, if I know that the terminal that I'm using is mintty, that is a good
> workaround. ÂBut I try to use the same .profile on both my linux and cygwin
> environments, and I'd prefer it to work with other terminals than just
> mintty. ÂIf there was a portable way to determine whether I'm running within
> mintty, I could use the above escape sequence, but I don't know of a good way
> to determine if I'm in mintty. ÂThe obvious method would be to check $TERM,
> but of course that doesn't work...

... and I can't change it to "mintty", because even if entries for it
were added to Cygwin's termcap and terminfo, any other system would
say "what?".

You could change it though, e.g.:

  mintty env TERM=mintty /bin/bash -l

And then have a bit in your .profile that checks for that TERM setting
and changes it to xterm afterwards.

Alternatively, mintty can be recognised by querying the "secondary
device attribute". If you send "\e[>c", it will currently reply with
"\e[>77;501;0c". The 77 (ASCII 'M') identifies mintty, the 501 is the
version number, and the last field is unused.

Btw, how do you deal with the problem that the 'kbs' terminfo entry on
the remote machine doesn't necessarily fit the terminal on your local


Problem reports:
Unsubscribe info:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]