[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

under cygwin incorrect prompt display with color code

From: Kelvin Lee
Subject: under cygwin incorrect prompt display with color code
Date: Tue, 17 Aug 2004 12:17:50 +1000

Configuration Information [Automatically generated, do not change]:
Machine: i686
OS: cygwin
Compiler: gcc
Compilation CFLAGS:  -DPROGRAM='bash.exe' -DCONF_HOSTTYPE='i686' -DCONF_OSTYPE='cygwin' -DCONF_MACHTYPE='i686-pc-cygwin' -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/local/share/locale' -DPACKAGE='bash' -DSHELL -DHAVE_CONFIG_H -DRECYCLES_PIDS  -I.  -I. -I./include -I./lib   -pipe -O2

uname output: CYGWIN_NT-5.0 kelvinpc 1.5.10(0.116/4/2) 2004-05-25 22:07 i686 unknown unknown Cygwin
Machine Type: i686-pc-cygwin

Bash Version: 3.0
Patch Level: 0
Release Status: release

    Under cygwin with the following prompt:
        PS1="address@hidden:\[\033[103m\]\w\[\033[m\]:\! \$ "
    Inside xterm, the prompt would become:
        address@hidden:~:999 $ $
    Notes the double $ signs. (Notes joe and machine are displayed in colors correctly.)
    The same PS1 works well on Linux boxes.
    So looks like a cygwin specific problem.
    Occasionally, the prompt can be displayed correctly (e.g. after pressing Tab for autocompletion).
    But then the command line would be displayed incorrectly, looks like this:
        address@hidden:~:999 $ $ ls t[TAB]
        test/ tmp/
        address@hidden:~:999 $ ls tt
    Notes the second prompt is correct now but the last 't' character becomes 'tt'.

    Simply set:
        PS1="address@hidden:\[\033[103m\]\w\[\033[m\]:\! \$ "
    under a cygwin xterm.

Kelvin Lee
// LANSA Product Centre
// LANSA Pty Ltd
// phone: +61 (2) 8907 0231
// mailto:address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]