How do I make my osascript compiled ASObjc program wait for me to click the NSLocationUsageDescription button? I have to be so fast for it to work or use the settings app.

Like I build it something like this:

osacompile -o build/ moo.applescript defaults write blah defaults write NSLocationUsageDescription "I need location perms to function." codesign blah blah

And it works too well! I get the prompt but it doesn’t wait for my response. The app exits. I still have the prompt to respond to. Say OK. Doesn’t work. :frowning:

It works well within SD8 to write it how I wanted it to function but SD8 wanted the perms for me to do like set locationManager to CLLocationManager's alloc()'s init() and waited, so that’s my purpose of doing this you understand, I want my own app to request the perms not the editor.

Anyway, I find this behavior interesting since do shell script command with administrator privileges does wait for my fingerprint.

To be clear, my “app” just wants to do 1 thing real quick using location detection then pass it along a larger pipeline but not like crazy large.

Idle loop it is across CLLocationManager authorizationStatus, I guess then.