Replacing Adobe app icons

cwaldrip
Valued Contributor

We've got multiple versions of some Adobe apps on some of our machines, and we thought it'd be nice to have slightly customized icons (2017 added to the bottom corner of the icon for example). It'd be nice if we can replace the icon with a post-install script, but it's not working.

I've got the icons converted to .icns files and their names changed as appropriate name for each app (ex. pr_app_icons.icns for Premiere). The icns files are installed in /tmp and a post-install script copies the files to [Adobe App]/Contents/Resources/, and changes the ownership and permissions to match the original icns file.

A restart of the Finder, and no change in the app icon. I kill the cache service (cfprefsd) and then kill the Finder, and no change.

Any idea what I'm missing. I'm thinking either a weird security feature or it's a hidden .icns file. But this looks to be the correct file in the /Contents/_CodeSignature/CodeResources file.

1 ACCEPTED SOLUTION

mm2270
Legendary Contributor III

Yeah, in experimenting with this just a little while ago, it doesn't appear so easy to get the new icon to show up in anything but the Get info window. Check them there and you may see the new icon show up. But as for the Finder, I haven't found the magic combination yet. It may involve deleting stored icon cache from the system and rebooting the Mac even! Not exactly that easy.

Back in the day, SetFile, part of the older Xcode tools, was able to help with this, but it's long been deprecated, and anyway, it requires having the Xcode cli tools installed.
If you're not opposed to using a 3rd party utility, there's fileicon, which you can find here: fileicon It can supposedly set icons for folders, which, technically, apps are folder bundles, so maybe it would work? I haven't tried it myself.

View solution in original post

6 REPLIES 6

mm2270
Legendary Contributor III

I believe the problem is you aren't naming the icns files the exact same name as the originals being used for the applications.
For example, if you run the following command against an app, it will tell you what icon file name it uses for the app. To my knowledge, the Info.plist is what dictates what the app uses, not just having an .icns file in the Resources folder.

defaults read /Applications/AppName.app/Contents/Info CFBundleIconFile

Usually that file will be found in the /Resources/ directory as you mentioned. But your new icons should have the same name, which would mean replacing the originals, or just renaming them and leaving them in the Resources folder.

Or, you could place the new icons as is with the custom names and modify the Info.plist so the app knows it should use your custom icon.

Edit: Actually, looking back at what you wrote, maybe you are naming them the right way? Is that "pr_app_icons.icns" the actual name of the Premiere icns? I don't have that app on my system so I can't check.

cwaldrip
Valued Contributor

Good tip regarding the defaults read for the icon name.

But yeah, I'm using the name of the existing .icns file, and the defaults read tip verified it's the correct name.

mm2270
Legendary Contributor III

Yeah, in experimenting with this just a little while ago, it doesn't appear so easy to get the new icon to show up in anything but the Get info window. Check them there and you may see the new icon show up. But as for the Finder, I haven't found the magic combination yet. It may involve deleting stored icon cache from the system and rebooting the Mac even! Not exactly that easy.

Back in the day, SetFile, part of the older Xcode tools, was able to help with this, but it's long been deprecated, and anyway, it requires having the Xcode cli tools installed.
If you're not opposed to using a 3rd party utility, there's fileicon, which you can find here: fileicon It can supposedly set icons for folders, which, technically, apps are folder bundles, so maybe it would work? I haven't tried it myself.

cwaldrip
Valued Contributor

@mm2270 fileicon did the trick!

Do you EVERY buy your own drinks at JNUC, or does everyone just chip in on an open tab for you. Add me to the list then. ;-)

cwaldrip
Valued Contributor

As a followup, there's the app icon cache... which is news to me. I guess this is the modern version of rebuilding the desktop. ;-)

sudo find /private/var/folders/ -name com.apple.dock.iconcache -exec rm {} ;
sudo find /private/var/folders/ -name com.apple.iconservices -exec rm -rf {} ;
sudo mv /Library/Caches/com.apple.iconservices.store com.apple.ic

mm2270
Legendary Contributor III

@cwaldrip Yep, that's actually what I was referring to above when I mentioned deleting icon cache. However, in my experiments, it didn't seem to have the necessary affect. The old/original icon was still showing on the app I messed with. Is it making the change appear for you when you delete those? If so, that's great, and would be more portable than using fileicon.
I'm glad I was able to help in any event.

As for drinks at JNUC, given I haven't been able to make JNUC the last couple of years, I haven't been able to cash in on any promised drinks. :/ I'm not sure yet if this year will be any different, but here's hoping!