Opened 9 years ago
Closed 4 years ago
#42 closed enhancement (fixed)
Add a /N switch to the history command
| Reported by: | Gregg Young | Owned by: | Gregg Young |
|---|---|---|---|
| Priority: | minor | Milestone: | Version-3.10 |
| Component: | Commands | Version: | 3.08 |
| Keywords: | Cc: |
Description
/N would add the item to the history list only if it not already there.
Change History (4)
comment:2 by , 7 years ago
| Milestone: | Version-3.09 → Version-3.10 |
|---|
Ticket retargeted after milestone closed
comment:3 by , 4 years ago
| Owner: | set to |
|---|---|
| Status: | new → assigned |
This is intended to check for dups when using /a. Consider changing /a to do this.
comment:4 by , 4 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
Rev 38287, 38309 HistNoDups=yes in INI makes /a add the item to the history list only if it not already there.
Note:
See TracTickets
for help on using tickets.

As a bit of a workaround, in my XWP Shutdown folder, I have an object which does this:
4OS2.EXE /c "history | perl -ne '/;/ or print unless $seen{$_}++' > C:\HOME\DEFAULT\.history && delay"This filters out those lines where I've mistakenly hit ";" instead of ":" (I should improve that to limit those to only those lines containing one letter before the semicolon, I 'spose) and non-unique lines. Thus, multiple occurrences of dir, cd, etc. get filtered when saving the history for re-reading at next startup.
This is no substitute for not cluttering up the list with the dupes in the first place, of course, so your RFE wouldbe quite useful, Gregg.