问题
With OSX Mavericks we now can make notifications with applescript pretty easily. However, there doesn’t seem to be a way to change the icon that appears to a custom one. Is there a way to accomplish this?
回答1:
display notification
will take application icon. You can set icon in bunlde content of applescript application.
set fileName to choose file "Select a Folder"
display notification "Parag Bafna" subtitle "Its working" & fileName

display notification text required
with title text optional
subtitle text optional
sound name text optional
回答2:
You change the icon by simply changing the icon of the script/app itself. Copy a picture you want as icon (⌘ + C), Right click your saved app/script file, "get info", click the upper left file icon, Paste (⌘ + V). If you save as a script bundle, you can also swap the icns file inside the bundle to your own (inside the Resources folder).
来源:https://stackoverflow.com/questions/19627018/change-the-icon-of-an-applescript-called-notification