03 August, 2007

HowTo fix command history in mc under Ubuntu

The program which I setup first of all after the Linux installation is mc (Midnight Commander).
It is very friendly and useful for me.

But in Ubuntu there is one problem with mc: shell's commands history is flooded with a garbage and with many ESC-symbols when I use mc.

E.g.:

cd "`echo -e '\057usr'`"
cd "`echo -e '\057usr\057X\061\061R\066\057bin'`"
cd "`echo -e '\057home'`"


I found the way how to fix this problem.
In the file .bashrc string:
export HISTCONTROL=ignoredups
should be replaced with:
export HISTCONTROL=ignoreboth

No comments: