How to delete history? like directory history, command history, etc?

English support forum

Moderators: white, Hacker, petermad, Stefan2

Joeyy
Junior Member
Junior Member
Posts: 60
Joined: 2016-09-20, 10:09 UTC

How to delete history? like directory history, command history, etc?

Post by *Joeyy »

I delete the Directory history records in the wincmd.ini And restart total commander. It doesn't work. The history is still there.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: How to delete history? like directory history, command history, etc?

Post by *ghisler(Author) »

The history is saved when you close TC. So you need to
1. Use Configuration - Change settings files directly
2. Close Total Commander (BEFORE saving wincmd.ini!)
3. Edit the wincmd.ini to remove the history
4. Save the wincmd.ini
5. Now re-open Total Commander
Author of Total Commander
https://www.ghisler.com
User avatar
petermad
Power Member
Power Member
Posts: 14739
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Re: How to delete history? like directory history, command history, etc?

Post by *petermad »

2Joeyy
I can recommend redirecting all the history-like sections of wincmd.ini to a history.ini file.

Then you can just delete the whole file,if you really want to clean up. Here are the sections I redirect:
[attrplugin]
RedirectSection=history.ini

[rename]
RedirectSection=history.ini

[SyncOptions]
RedirectSection=history.ini

[Selection]
RedirectSection=history.ini

[SearchName]
RedirectSection=history.ini

[SearchIn]
RedirectSection=history.ini

[SearchText]
RedirectSection=history.ini

[RenameTemplates]
RedirectSection=history.ini

[RenameSearchFind]
RedirectSection=history.ini

[RenameSearchReplace]
RedirectSection=history.ini

[left]
RedirectSection=history.ini

[right]
RedirectSection=history.ini

[lefttabs]
RedirectSection=history.ini

[righttabs]
RedirectSection=history.ini

[Command line history]
RedirectSection=history.ini

[RightHistory]
RedirectSection=history.ini

[LeftHistory]
RedirectSection=history.ini

[MkDirHistory]
RedirectSection=history.ini

[NewFileHistory]
RedirectSection=history.ini

[PluginDuplicates]
RedirectSection=history.ini

[DirSelection]
RedirectSection=history.ini

[ButtonbarCache]
RedirectSection=history.ini
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50b4 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Alexisback
Junior Member
Junior Member
Posts: 80
Joined: 2016-10-26, 20:04 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Alexisback »

Is it possible to do this?
when Total Commander closes, the history.ini file is automatically deleted
User avatar
petermad
Power Member
Power Member
Posts: 14739
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Re: How to delete history? like directory history, command history, etc?

Post by *petermad »

when Total Commander closes, the history.ini file is automatically deleted
If yiu start TC via a bat or cmd file, you can delete the file in a second line.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50b4 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Joeyy
Junior Member
Junior Member
Posts: 60
Joined: 2016-09-20, 10:09 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Joeyy »

Thanks to all the answerers, especially the author Ghisler! :D
Alexisback
Junior Member
Junior Member
Posts: 80
Joined: 2016-10-26, 20:04 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Alexisback »

petermad wrote: 2019-03-27, 01:05 UTC
when Total Commander closes, the history.ini file is automatically deleted
If yiu start TC via a bat or cmd file, you can delete the file in a second line.
Hi petermad :)

I have a portable version of Total Commander
(InstallDir =% COMMANDER_PATH%)
is started from exe file (TOTALCMD.EXE)
I don't have all those lines in the file wincmd.ini,
explain how to delete history.ini automatically when the program is closed :| :idea:

thank you
User avatar
obeg
Junior Member
Junior Member
Posts: 43
Joined: 2006-09-28, 09:20 UTC
Location: Sweden

Re: How to delete history? like directory history, command history, etc?

Post by *obeg »

If you only want to delete the Directory history after each close, then there is the possibility to turn off the saving. This is done in the Configuration => Operation and "Save on exit", uncheck Directories
Alexisback
Junior Member
Junior Member
Posts: 80
Joined: 2016-10-26, 20:04 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Alexisback »

obeg wrote: 2019-03-27, 09:50 UTC If you only want to delete the Directory history after each close, then there is the possibility to turn off the saving. This is done in the Configuration => Operation and "Save on exit", uncheck Directories
and all unchecked in "save to exit"
I close the program, reopen and history.ini is still there, it is not deleted :( :roll:
User avatar
obeg
Junior Member
Junior Member
Posts: 43
Joined: 2006-09-28, 09:20 UTC
Location: Sweden

Re: How to delete history? like directory history, command history, etc?

Post by *obeg »

"Save on exit", uncheck Directories will stop future entries to be written. So you need to do the delete of the existing file manually.

If you have redirected to a history.ini, then delete it when Total Commander is closed. Or edit the wincmd.ini, also when Total Commander is closed
Alexisback
Junior Member
Junior Member
Posts: 80
Joined: 2016-10-26, 20:04 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Alexisback »

does not work, deleted the file but at opening it is always there :|

this is the wincmd.ini configuration

Code: Select all

[RightHistory]
RedirectSection=history.ini

[LeftHistory]
RedirectSection=history.ini

[MkDirHistory]
RedirectSection=history.ini

[RenameTemplates]
RedirectSection=history.ini

[searches]
RedirectSection=history.ini

[SearchName]
RedirectSection=history.ini

[SearchIn]
RedirectSection=history.ini

[SearchText]
RedirectSection=history.ini

[RenameSearchReplace]
RedirectSection=history.ini

[rename]
RedirectSection=history.ini

[RenameSearchFind]
RedirectSection=history.ini
User avatar
Wilhelm M.
Power Member
Power Member
Posts: 990
Joined: 2003-06-05, 10:45 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Wilhelm M. »

If you redirect all those sections to an "external" file (outside wincmd.ini), then TC possibly creates this file when started. But it should stay empty if saving of directories is disabled.
Grüße/Regards,
Wilhelm
Alexisback
Junior Member
Junior Member
Posts: 80
Joined: 2016-10-26, 20:04 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Alexisback »

Wilhelm M. wrote: 2019-03-27, 12:01 UTC If you redirect all those sections to an "external" file (outside wincmd.ini), then TC possibly creates this file when started. But it should stay empty if saving of directories is disabled.
the history.ini file does not remain empty :| :?:

Image: https://i.imgur.com/ebmWmnX.png
User avatar
Wilhelm M.
Power Member
Power Member
Posts: 990
Joined: 2003-06-05, 10:45 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Wilhelm M. »

No? Then what's in it? Give a view lines as an example. Maybe it contains only the section headers.
Grüße/Regards,
Wilhelm
Alexisback
Junior Member
Junior Member
Posts: 80
Joined: 2016-10-26, 20:04 UTC

Re: How to delete history? like directory history, command history, etc?

Post by *Alexisback »

Wilhelm M. wrote: 2019-03-27, 14:32 UTC No? Then what's in it? Give a view lines as an example. Maybe it contains only the section headers.
This :roll:

Code: Select all

[MkDirHistory]
0="  TEST 3"
1="  TEST 2"
2="  TEST 1"
Post Reply