Re: Is setting a custom folder icon possible?
site_archiver@lists.apple.com Delivered-To: installer-dev@lists.apple.com Hi Stéphane, Am 17.05.2005 um 22:47 schrieb Stéphane Sudre: On mardi, mai 17, 2005, at 12:39 PM, Mike Fischer wrote: Hi, Great! 2 solutions: -------8<-------8<-------8<-------8<------- #!/bin/sh exit 0 OK, no problem. I'll do the testing then. Correct? Thanks a lot for your help! Mike -- Mike Fischer Softwareentwicklung, EDV-Beratung Schulung, Vertrieb Address: Bundesstrasse 9, D-20146 Hamburg, Germany Phone: +49 (0)40/45038886, Fax: +49 (0)40/45038887 _______________________________________________ Do not post admin requests to the list. They will be ignored. Installer-dev mailing list (Installer-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/installer-dev/site_archiver%40lists.a... I have (well, actually a friend of mine who is not on this list has) been trying to get a Mac OS X installer package to install a folder with a custom icon. So far it looks like the Icon\n file is correctly installed (including the resource fork which holds the icon data) but the custom icon Finder flag is not set on the enclosing folder. (As evidenced by /Developer/Tools/GetFileInfo -a <path to folder>. The "c" is lowercase indicating the flag not set.) Is it possible to set a custom folder icon using installer packages? If so, how? Yes. o you're 100% sure the target machine and OS has the Developer Tools installed: Unfortunatly this can not be taken for granted. In fact it is unlikely, that the target audience will have the developer tools installed IMHO. o you're not 100% sure the target machine will have the Developer Tools installed: Keep the same scenario as above but instead of using the /Developer/Tools/SetFile tool, you will need to use your own. Add the tool to the Resources and in the postflight script call it with: "$1/Contents/Resources/setHasCustomIcon" -C "/Applications/Adobe Photoshop 7" -------8<-------8<-------8<-------8<------- OK that sounds good. I can come up with a small tool to set the flag (or use the Swedish example code you provided). You would need to create a new CoreServices tool. Warning I didn't test the code, I just checked it was compiling. So to summarize, I understand that: - There is no intrinsic method to set Finder flags on installed files or folders in an installer package; - Using a postflight script it is possible to trigger an executable that sets Finder flags; - Since no executable, capable of setting Finder flags, exists on a standard install of Mac OS X, a suitable executable must be provided in the installer package. This email sent to site_archiver@lists.apple.com
participants (1)
-
Mike Fischer