This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: BASH question HISTCONTROL


Patrick,

Check out HISTIGNORE. It's not about duplicates, but I use it to get rid of 
things I do constantly but which I don't really want in the history, like: 
cd, td, fd, wd, ll, ls, lf, lt, j, ok (yeah, most of those are aliases or 
shell procedures I define as shorthands for or embellishments of common or 
built-in commands: td (pushd), fd (popd), wd (pwd), ok (echo ok^G), j (jobs)).

HISTIGNORE repsects glob wildcards, by the way.

You might get better results from this than from duplicate control. At 
least it can be complementary.

Randall Schulz
Mountain View, CA USA


At 07:27 2001-06-13, Patrick Ohnewein wrote:
>Now, may be OFF TOPIC, but don't know where to ask this.
>
>I use 'HISTCONTROL=ignoreboth' and used 'HISTCONTROL=ignoredups' before.
>ignoreboth implies ignoredups, but I am looking for a manner to avoid 
>getting a command more than once in my history file (.bash_history), 
>ignoredups only avoids multiple CONSEQUENT equal lines.
>-- EXTRACT from Bash Reference Manual ---
>Set to a value of `ignoredups', it means don't enter lines which match the 
>last entered line.
>---------------------------------------
>
>Does some of u know a manner to avoid any duplicates in the history-file. 
>I set my HISTSIZE and HISTFILESIZE to 5000 and may be I will increase, but 
>it would be more efficient to just avoid this duplicates.
>
>To explain my problem...
>
>cu pazzo


--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]