On Fri, 27 Dec 2019 20:38:31 +0300 Andrey Repin wrote: > Greetings, All! > > Despite having "chcp.com 65001" in .bashrc, current codepage now reset to > CP1251 (which is rather surprising, considering that default console codepage > for russian cyrillic is 866). > > I don't have the full understanding of what's happening, but somehow > PROMPT_COMMAND is involved. > > The observed effect is this: > I have > 1. > PROMPT_COMMAND='printf > "\e]0;${debian_chroot:+($debian_chroot)}${USER:-$USERNAME}@${HOSTNAME}: > ${PWD/$HOME/\~}\a"' > 2. > chcp.com 65001 > > in the .bashrc, in that order. > When I start mintty (as login shell or as regular interactive shell), chcp > reports CP1251. > If I run something like > > $ uname -a; chcp; chcp 65001; chcp > > It will report that CP was changed successfully > > $ uname -a; chcp; chcp 65001; chcp > CYGWIN_NT-6.1 daemon2 3.1.2(0.340/5/3) 2019-12-21 15:25 x86_64 Cygwin > ’ҐЄгй п Є®¤®ў п бва Ёж : 1251 > Active code page: 65001 > Active code page: 65001 > > but an immediate call to chcp afterwards reports > > $ chcp > ’ҐЄгй п Є®¤®ў п бва Ёж : 1251 > > Ooopsss??
Thanks for the report. I have found the cause in pty code. I will submit a patch for this issue shortly. -- Takashi Yano <takashi.y...@nifty.ne.jp> -- 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