Ability to get unused apps


#1

Hi !

I was wondering if I could get a list of unused apps from the app usage information.
I tend to install alot of apps that I forget to uninstall, and was wondering how about I would get to create this plugin.


#2

In a couple of minutes I was able to make this

To do this, go into the “Query” tab in the webui and paste this

afk_events = query_bucket(find_bucket(‘aw-watcher-afk_’));
window_events = query_bucket(find_bucket(‘aw-watcher-window_’));
window_events = filter_period_intersect(window_events, filter_keyvals(afk_events, ‘status’, [‘not-afk’]));
apps = merge_events_by_keys(window_events, [“app”]);
apps = sort_by_duration(apps);
RETURN = apps;

Afterwards you can set the start/end dates you want the results to be in, but if you select a very long period of time (more than a few weeks) it might lag quite a lot.

This is not really a proper solution to your issue, but it works :slight_smile:


#3

Thank you for the reply Johan, its been really helpful.

window_events = filter_period_intersect(window_events, filter_keyvals(afk_events, ‘status’, [‘not-afk’]));
This is getting everything that is “not-afk”?

Is there a solution to be able to make the lag faster or contain some of the calculation?

Cheers,
Kye