From c4f7a47e02e61365d432e4195400ed89dab6b194 Mon Sep 17 00:00:00 2001 From: Audric Schiltknecht Date: Wed, 7 Nov 2012 00:26:14 +0100 Subject: Ignore lines starting with space in bash history --- bash/.bashrc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'bash') diff --git a/bash/.bashrc b/bash/.bashrc index 301f9ac..39508c5 100644 --- a/bash/.bashrc +++ b/bash/.bashrc @@ -5,8 +5,9 @@ # If not running interactively, don't do anything: [ -z "$PS1" ] && return -# don't put duplicate lines in the history. See bash(1) for more options -export HISTCONTROL=ignoredups +# don't put duplicate lines in the history, not lines starting white space. +# See bash(1) for more options +export HISTCONTROL=ignoreboth # append to the history file, don't overwrite it shopt -s histappend -- cgit v1.2.3-70-g09d2