Recent behavior changes driving me nuts
Posted Jul 4, 2006 7:54 UTC (Tue) by
jzbiciak (
✭ supporter ✭, #5246)
Parent article:
CLI Magic: Using command history in the bash shell (Linux.com)
I know there are probably more "correct" ways to do this, but this is a long standing habit. I have a tendency to open a line with a # (thereby making it a comment) and then expanding out something in my history with !.
So, for example:
#!t
might expand out into
#tail -f /var/log/messages
I then up-arrow, remove the # and edit the line to my heart's content if it was the line I'm looking for. This works great w/ older bash, such as 2.05a. Recent bash versions, such as 3.1.17, don't seem to do this.
Does anyone know a way to reenable this in bash?
(
Log in to post comments)