Posted on ‎09-20-2017 06:54 AM
Hello, I am trying to install a program that resides in a folder with a custom folder. After installation the icon file looses its attributes and the icon itself does not display. That means, composer displays things fine, but after the installation the folder will lose the icon.
Posted on ‎09-20-2017 09:14 AM
I iconize a folder with the following script
#!/usr/bin/env python
import Cocoa
import sys
Cocoa.NSWorkspace.sharedWorkspace().setIcon_forFile_options_(Cocoa.NSImage.alloc().initWithContentsOfFile_(sys.argv[1].decode('utf-8')), sys.argv[2].decode('utf-8'), 0) or sys.exit("Unable to set file icon")
Executing by running:
python set-image.py "locationtopngyouwanttouse.png" fulllistingtofolder
eg
python set-image.py Office-2016-Office.png /Applications/Microsoft Office 2016/
Posted on ‎09-21-2017 06:34 AM
I had that happen to me once. Within Composer, make sure the permissions on the icon file are set to Read for all.
Posted on ‎04-21-2020 06:26 AM
I came along this question and tried out the idea of @AVmcclint. It also worked out for me! đź‘Ť
The problem was that I removed the icon-file from the created package in Composer.
I added the picture with copy-paste method in the Finder > Information window.
So just open the picture, copy and paste it on the Foldericon. After that I checked the privileges in Composer, the Icon file is not present for the users but works as folder icon 🙂