HI ,
   launch an applescript / shell script when uninstall button is clicked . This 
should first quit  the App and wait for it to terminate and then delete the 
bundle and plist


Thanks
Rajendran P


On 10/27/10 5:46 PM, "eveningnick eveningnick" <eveningn...@gmail.com> wrote:

Hello
I have an application that creats, when installed, a bundle in
"Applications" and registers a .plist file for launchd in
~/Library/LaunchAgents (the agent is located in that bundle, and its
process is launched everytime the OS starts).
Thus, i can't let a user just to move bundle to the Trash bin, when he
wants to get rid of it. Thats why, in a "control panel" of my
application, i placed a button "Uninstall", which
1) stops the Agent
2) deletes the plist file
3) [should delete the bundle]

This control panel is located in this bundle, that has to be deleted.
And in Mac OS 10.6 a bundle whose application is running can't be
deleted.
What could i do here to delete the bundle? What is usually done in such cases?
o) After "uninstalling", ask user to manually move bundle to a trash
bin, and then terminate control panel application? Seems pathetic,
especially when user already pressed "Uninstall".
o) Copy a "bundle-deleting script" to the "autorun once", that will
launch next time with the next system boot? It seems like a good idea,
but could it be done somehow without leaving traces afterwards?
o) Copy to some "autocleanined" (like temp or something) folder a
script, launch it and terminate control application. That script will
wait, till the control app is terminated , and then remove the bundle.
But does such a folder exist in MacOS? and how could it possibly be
done?

I don't want to rubbish  the user's Mac, if he/she doesn't like my App :)

Thanks!
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/rpichaim%40juniper.net

This email sent to rpich...@juniper.net

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to