Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

5
  • 1
    Better than my answer of $HISTIGNORE would have been. +1 Commented Feb 28, 2011 at 14:12
  • 1
    learn something new every day. Commented Feb 28, 2011 at 15:29
  • 2
    I usually set this in /etc/profile as HISTCONTROL=ignoreboth and export the HISTCONTROL variable. Commented May 15, 2011 at 22:55
  • This doesn't seem to work for me? It seems to write to history, but just include the space in front. 486 echo test 487 history 488 echo testspace 489 history Commented Jan 3, 2013 at 13:45
  • Disregard that last comment, looks like it works in Ubuntu but not Debian/other OS's. Commented Jan 5, 2013 at 11:37