Re:LeakedIn
by corin_ on Wednesday June 06, 2012 @04:27PM
(#4076019)
Just pop a space at the beginning and it won't go into shell history.
[ Parent
| on HN ]
It does for me
> echo test
test
> history
...
6730 echo test
6731 historySet this in your .bashrc
HISTCONTROL=ignorespace
Or even better, though unrelated to this topic... Also get it to ignore duplicates that come next to each other. HISTCONTROL=ignoredups:ignorespaceThat's a bash-ism that's controlled by the $HISTCONTROL environment variable, not universally-applicable advice. $HISTCONTROL set to "ignorespace" or "ignoreboth" may or may not be the default, depending on your distribution.
Yeah already replied below specifying that - I was under the impression that it's default to on in most distros, but don't actually have a clue which do/don't.
it will still be in ps output for a short while...
Ultra paranoid. I like the way you think.