Le 6 nov. 06 à 14:07, Luther Fuller a écrit : The 'setFile' command has a custom icon property that may work. Some time ago I tried to set a folder icon with setFile, but could not get it to work. I did notice that a folder with a custom icon has either 1. an invisible file named "icon " (That's "icon" & return) or 2. An invisible file named ".VolumeIcon.icns"
yes you're right, if i look into folder on which (using get info command+i) i do have paste a custom icon i get :
~/Pictures/Folders/folder_cobalt%> ls -al total 128 drwxr-xr-x 3 yvon yvon 102 Nov 6 14:52 . drwxr-xr-x 39 yvon yvon 1326 Nov 6 14:52 .. -rw-r--r-- 1 yvon yvon 0 Nov 6 14:52 Icon?
then as you've writen the ? stanfs for the return on the terminal ?
also you're other case :
~/Pictures/Folders/folder_cobalt%> locate .VolumeIcon.icns /.VolumeIcon.icns /Applications/.VolumeIcon.icns [...] /Users/yvon/work/RubyCocoa/VLCRecorder/dist/.VolumeIcon.icns
the latest being installed, as far as i remember well, using "Icon Machine" being able to attach an icon from the menu :
File > Apply Icon to...
i've tried, when writing this reply an experiment :
i take a icns Icon file names "folder_cobalt.icns" put it in a given folder (with a generix icon then) and do :
$ mv folder_cobalt.icns .VolumeIcon.icns
verify by : ~/Pictures/Folders/folder_cobalt/folder_cobalt%> ls -al total 264 drwxr-xr-x 3 yvon yvon 102 Nov 6 15:08 . drwxr-xr-x 4 yvon yvon 136 Nov 6 15:06 .. -rw-r--r-- 1 yvon yvon 65146 Nov 6 15:05 .VolumeIcon.icns
even forcing the finder to relaunch i don't see this icon and also even after having made a copy of this folder with it's icon...
may be this need a computer restart,
i'll let new know if that work, because it could be done via AppleScript using a do shell script.
best,
Yvon |