Application Usage Smart Group

MathiasO
New Contributor II

Hey Guys,

is there a way to build a smart group for "not used" Apps in the last (maybe) 10 days?
We want to shorten our Browser List and remove Firefox, but first to all Devices that don't use Firefox.

I checked the box for "Collect Application Usage" and we see the Usage Information in the Computer Objects. I just need a way to collect all information into one Group to scope the removal script.

Thanks for some Advice!

1 ACCEPTED SOLUTION

sdagley
Esteemed Contributor II

@MathiasO The Application Usage data isn't available as a Smart Group criteria. You could create an EA for each of the apps you're interested to see when it was last launched, and use that as the criteria for a Smart Group to target your removal script policy. Here's an example EA that returns the last time VMware Fusion was launched (make sure to set the EA data type as Date):

 

#!/bin/sh

AppToCheck="/Applications/VMware Fusion.app"
Result="2000-01-01 00:00:01"

if [ -d "${AppToCheck}" ]; then
	Result=$(mdls -name kMDItemLastUsedDate "${AppToCheck}" | cut -f 3,4 -d \ )
fi

echo "<result>$Result</result>"

 

 

View solution in original post

4 REPLIES 4

MathiasO
New Contributor II

Hey!

That's not really what I meant. 
I searched for JAMF PRO SMART GROUPS criteria for collecting Computers Application Usage.

jamf-42
Valued Contributor II

you can't, there isn't an option. All you can do is search here: Capture 2023-01-30 at 12.44.44.png

this provides some very basic output that cannot be exported.. and you can't even save the search... 

 

sdagley
Esteemed Contributor II

@MathiasO The Application Usage data isn't available as a Smart Group criteria. You could create an EA for each of the apps you're interested to see when it was last launched, and use that as the criteria for a Smart Group to target your removal script policy. Here's an example EA that returns the last time VMware Fusion was launched (make sure to set the EA data type as Date):

 

#!/bin/sh

AppToCheck="/Applications/VMware Fusion.app"
Result="2000-01-01 00:00:01"

if [ -d "${AppToCheck}" ]; then
	Result=$(mdls -name kMDItemLastUsedDate "${AppToCheck}" | cut -f 3,4 -d \ )
fi

echo "<result>$Result</result>"

 

 

MathiasO
New Contributor II

Amazing!

Very Helpful, thanks!

Have a great Day!