kspi / dmenu-frecency

A dmenu-based desktop application launcher
MIT License
33 stars 8 forks source link

Visited non-desktop programs remain in cache when switching to '"scan-path": true' #11

Closed willemw12 closed 9 years ago

willemw12 commented 9 years ago

Not sure if this is a bug (maybe --read-app is supposed to do this), however it you start with '"scan-path": true'. Launch a non-desktop programs. Then switch to '"scan-path": true' and do a 'dmenu-frecency --read-app', then the visited non-desktop programs are still in the program/app cache. Expected a full refresh of the cache after the switch (automatically or with a new dmenu-frecency command line option).

kspi commented 9 years ago

This is by design: every visited program is saved to the 'visits' dictionary ant never cleared. This allows entering and saving custom command lines which are not in the list. If you want to clear it, you can remove the state file.

The current design is pretty complicated, I'll think about simplifying it.

willemw12 commented 9 years ago

Also, you cannot remove a non-desktop app from the cache without deleting the whole cache (the state file).