How do I enable location services for a particular app from command line?

I've created an .app python application and I need to enable location services for it from command line, because in my setup there is no access to GUI.

So basically, I wan't to achieve doing

System Preferences > Security & Privacy > Privacy > Location Services and tick <app_name>

from command line. How do I do that?

Answered by DTS Engineer in 724685022

There isn’t a way to do this, because allowing this would make for a trivial privacy bypass.

For most privacy settings you can control this using a configuration profile with the com.apple.TCC.configuration-profile-policy payload but I don’t see location listed there.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Accepted Answer

There isn’t a way to do this, because allowing this would make for a trivial privacy bypass.

For most privacy settings you can control this using a configuration profile with the com.apple.TCC.configuration-profile-policy payload but I don’t see location listed there.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

How do I enable location services for a particular app from command line?
 
 
Q