Re: Uninstall script
Re: Uninstall script
- Subject: Re: Uninstall script
- From: Philip Aker <email@hidden>
- Date: Fri, 29 Feb 2008 06:37:32 -0800
On 08-02-28, at 22:05, SVV Satyanarayana wrote:
Problem: I am writing some application using carbon/cocoa framework. It includes plugins, dylibs etc. It is packaged in such a way that during install it needs admin rights ie it will for authorization at the time of install. Similarly at the time of uninstall from finder(ctrl+click and select "Move To Trash" it is automatically asking authorization). The application is installed in /Applications and dependencies(plugins, dylib, config files etc) in /Library/MyAppName. I want to write some apple script that will uninstall all the application+dependencies. It must ask only once for the authorization.
The standard method to install an application like yours is to use the PackageMaker application. When it installs your application, it will put a <MyApp>.pkg in /Library/Receipts and possibly a .bom in /Library/Receipts/boms. Then, in your uninstaller script, you will mostly likely run a shell script which uses 'lsbom' to get the listing of all the installed items to remove. Run this script will the AppleScript command:
do shell script "blah blah blah..." with administrator privileges I want the script to be installed as different bundle while installation.
When you create the disk image for your distribution put the installer package created by PackageMaker and your uninstaller script application at the top level of the disk.
Also can you tell me whether I have to save the script as "Application" or "Script Bundle" or "Application Bundle" etc
You will probably want to save your script as an Application bundle so you can include any shell scripts it will run in its /Resources/Scripts subfolder.
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden