I use bash shell
$ bash --version
GNU bash, version 3.2.25(1)-release (x86_64-redhat-linux-gnu)
Copyright (C) 2005 Free Software Foundation, Inc.
$
Sometimes, when typing a command on the prompt that is pretty lengthy and does not fit in the current line, instead of displaying the extra characters on the next line, bash starts again on the current line.. replacing the characters that were there and making a mess.
what should happen :
|---------------------------------------------|
| $ my big long command takes a lot of argumen|
| s and does not fit in a single line |
| |
|---------------------------------------------|
what happens instead :
|---------------------------------------------|
| s and does not fit in a single linef argumen|
| |
| |
|---------------------------------------------|
- The issue is intemittent
- If I resize my shell window to really small width, normal behaviour is restored
Does anyone have any idea what is happening here?
$ echo $TERM
xterm
$ echo $PS1
\[\e[30m\][\t]\[\e[0m\]\[\e]0;\w\a\]\[\e[30m\][\W]$
$
TERMset to? Do you have any color or other formatting sequences in yourPS1? – Dennis Williamson Jan 8 '11 at 18:38shopt -s checkwinsizeor put it in your~/.bashrc. (The command makesbashrecheck the window's size every time the prompt is displayed.) – grawity Jan 8 '11 at 20:08