From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 114432 invoked by alias); 17 Aug 2018 14:37:04 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 114379 invoked by uid 89); 17 Aug 2018 14:37:04 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-0.2 required=5.0 tests=AWL,BAYES_00,KAM_ASCII_DIVIDERS,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE autolearn=no version=3.3.2 spammy=ups, scroll X-HELO: mout.kundenserver.de Received: from mout.kundenserver.de (HELO mout.kundenserver.de) (212.227.126.135) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 17 Aug 2018 14:37:02 +0000 Received: from [192.168.178.45] ([95.91.209.148]) by mrelayeu.kundenserver.de (mreue001 [212.227.15.167]) with ESMTPSA (Nemesis) id 0MWbbG-1fNT7J0suI-00XeR5 for ; Fri, 17 Aug 2018 16:36:59 +0200 Subject: Re: Fw: When scrolling through history in cygwin terminal window line gets garbled To: cygwin@cygwin.com References: <1372072396.8455798.1534430210374.ref@mail.yahoo.com> <1372072396.8455798.1534430210374@mail.yahoo.com> <1179039299.9023936.1534512963906@mail.yahoo.com> From: Thomas Wolff Message-ID: <8098c8d2-38ab-0fc0-5eea-8d7009b821e8@towo.net> Date: Fri, 17 Aug 2018 16:26:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <1179039299.9023936.1534512963906@mail.yahoo.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2018-08/txt/msg00229.txt.bz2 Am 17.08.2018 um 15:36 schrieb surendar jeyadev via cygwin: > I am having a similar issue to that pictorially shown here: > > > https://unix.stackexchange.com/questions/344502/when-scrolling-through-history-in-cygwin-terminal-window-line-gets-garbled > > > This is new to me as I have been using Cygwin on a Windows 7 > > machine for several years without encountering this problem. > > (Of course, that Cygwin build was from 5 or 6 years back.) > I just moved to a Windows 10 machine and installed Cygwin from scratch a couple of days back and ran into the issue. > > Using the UP arrow to go up the history list, I have no problem till I hit a long command (in the case shown below the problematic command was about 50 characters long). When going one step further up the history list, the leading characters of the long command stay on the command line. I cannot backspace/delete them. > > I am using mintty from the standard distribution. > > Specific example. I issue a 'history' command to show the > > history and then use the UP arrow key to scroll upwards. After 6 Ups, I reach command no. 33 as shown below. > > ================================ > sita 41 $ history > 2 vi .bash_profile > 3 quit > 4 eixt > 5 exit > 6 histoyr > 7 history > 8 vi .bash_profile > 9 vi .bash_profile > 10 exit > 11 history > 12 cd /usr/share > 13 ls > 14 cd > 15 history > 16 exit > 17 history > 18 history > 19 exit > 20 sdafasfas > 21 history > 22 cp /usr/share/vim/vim*/vimrc_example.vim ~/.vimrc > 23 history > 24 cp /usr/share/vim/vim*/vimrc_example.vim ~/.vimrc > 25 history > 26 ls > 27 cd > 28 vi .bash_profile > 29 exit > 30 history > 31 exit > 32 cygcheck -s -v -r > cygcheck.out > 33 history > 34 history > 35 ls > 36 cd > 37 pwd > 38 ls > 39 history > 40 exit > 41 history > sita 42 $ history > ================================ > > Now I move up one more step an get > > ================================ > .... > .... > 30 history > 31 exit > 32 cygcheck -s -v -r > cygcheck.out > 33 history > 34 history > 35 ls > 36 cd > 37 pwd > 38 ls > 39 history > 40 exit > 41 history > sita 42 $ cygcheck -s -v -r > cygcheck.out > ================================ > > which is just what is expected. One more and we get > > ================================ > 31 exit > 32 cygcheck -s -v -r > cygcheck.out > 33 history > 34 history > 35 ls > 36 cd > 37 pwd > 38 ls > 39 history > 40 exit > 41 history > sita 42 $ cygcheckexit > ================================ > > Command 31 (exit) now has the extra characters pre-pending the entry on the history list. > > Hitting a return here executes the 'exit', though. > This seems to work for other commands. It appears as though the characters have no effect. But, they do cause a bit of confusion! > > Also I noticed that if I input a really long string for a command, the characters that should be in a new line over write the leading characters of the command -- that is, there is no line feed when the text wraps around. > > Would greatly appreciate any help in fixing this. > > The 'cygcheck' output is attached. > > If you need any further information about the mintty set up, please let me know. > > tia. Please test the following: * Set you prompt to some basic string, e.g. PS1=%. Does that change anything? * Mintty 2.7.5 changed the default wraparound behaviour to become compatible with the xterm default. With setting -o OldWrapModes=true, does that change anything? * Can you cross-test this in xterm? * Does it happen in a freshly-started mintty? If it only happens later, which programs did you run in the meantime? * Make a screen log demonstrating a minimal test case, please. -- 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