Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Automatically add GrowlMail plugin compatibility to the latest version
# Updates the Growl Mail plugin when unknown compatibility preemptive deactivation happens.
# This consists in finding the “compatibility UUID” for the new Mail version, and adding it to the supported UUIDs of GrowlMail.
# See for more details on the procedure.
# Author: Matti Schneider <>
# Either ~/Library or /Library depending on the type of install (local or global).
INSTALL_ROOT="/Users/`whoami`/Library/Mail/" # the default is to assume a local install
read -n 1 -p "The plugin update procedure will start by quitting Mail. Press enter when you're ready to have Mail killed."
killall Mail 2> /dev/null # quit
uuids=$(defaults read MessageTracerInfo | grep UUID | cut -d '"' -f 2) # here are the new UUIDs we need to add to the bundle's supported list
deactivatedBundlesFolder="$(ls -1 $INSTALL_ROOT | grep "Bundles (")" # the deactivated folder name is localized, so we can only rely on its name having a parenthesis
if ! [[ -e "$INSTALL_ROOT/$deactivatedBundlesFolder/$BUNDLE_NAME" ]]
echo "No deactivated GrowlMail bundle found. Aborting."
exit 1
mv "$INSTALL_ROOT/$deactivatedBundlesFolder/$BUNDLE_NAME" "$DEST_NAME"
defaults write "$DEST_NAME/Contents/Info" SupportedPluginCompatibilityUUIDs -array-add $uuids
echo "Done! :)"
open -a Mail
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment