How to restore your Apple Mail rules from Time Machine backup in El Capitan

I have an elaborate set of rules that manage my work email.  Due to a buggy plugin, I lost them recently.  After a few moments of panic, I started researching.  After piecing together what I found on the Interwebs and knowledge I’d gained while debugging said buggy plugin, I found a safe, reliable way to restore mail rules with or without iCloud sync running. *

  • Quit Mail if it’s running, just to be safe
  • Open ~/Library/Mail/V3/MailData (Select the Go menu in the Finder and hold the option key down to see the Library folder)
  • Click on SyncedRules.plist
  • If you’re syncing your rules via iCloud Drive, do this bit of scariness (if you’re not sure whether you’re syncing or not, open System Preferences > iCloud, click “Options…” next to iCloud Drive, see if Mail is checked.  If it is, you’re syncing rules with iCloud Drive):
    • With sync still on, delete all your existing mail rules (iCloud will try to merge your rules later – this way it’ll merge with nothing)
      • Open Mail
      • Go to Preferences > Rules
      • Select all your rules
      • Click Remove to remove all your rules
        • This deletion will sync to iCloud and your other Macs.  btw, it’s probably a good idea to have any other Macs you sync with on for this just to make sure their rules are kept current.
      • Wait around 5 seconds just in case Mail needs to do something to communicate your rule deletion to iCloud
      • Quit Mail
    • THEN, turn off iCloud sync:
      • Open System Preferences > iCloud
      • Click “Options…” in the iCloud Drive line
      • Uncheck Mail
  • Restore SyncedRules.plist from Time Machine **
    • SyncedRules.plist still selected?  Good, Run Time Machine
    • Go back in time, looking at the “modified” time of SyncedRules.plist, until the “modified time” is just before you broke your rules
    • Click the Restore button.  If/when prompted, Replace the old broken rules file (I mean, keep both if you want, but it’s probably already in time machine and if you wanted it, you wouldn’t be doing all this)
  • If you’re not syncing with iCloud Drive, you’re done.  If you are syncing with iCloud Drive, turn Mail syncing back on now:
    • Open System Preferences > iCloud
    • Click “Options…” in the iCloud Drive line
    • Check Mail

At this point, you can launch Mail.  Your rules should be in the state they were at the time of the backup file you restored.  You may need to enable the rules (click the checkboxes) – I did.  (If you’re curious, I think the reason is that Mail stores the enabled state of rules in RulesActiveState.plist.  You probably could restore that file from Time Machine above if you had a really specific set of on/off settings you wanted to keep – I didn’t try).  If you sync your rules with iCloud drive, the restored rules should now be synced to your other computers as well – the sync happens within a few seconds (if they were online during this process – if they were off and have stale old rules, they should update to the new rules, but I haven’t tried that).

* In case you haven’t been looking around on the Interwebs, With or without iCloud sync is important because if you just restore SyncedRules.plist, it will be immediately replaced when you run Mail if you’re using iCloud to sync your rules.  (I use “iCloud” and “iCloud Drive” interchangeably here – rules sync happens using iCloud Drive).  If you just turn off Mail’s iCloud sync, restore SyncedRules.plist, and turn iCloud sync back on, you’ll get a merged mess of whatever was in iCloud (e.g. the rules you’re replacing) and the new rules.  The technique in this article restores your old rules and syncs them as is to iCloud (because there’s nothing there to merge).

** SyncedRules.plist stores your rules – I used Time Machine, but if you have a backup copy anywhere, e.g. CrashPlan, you can use that too; we’re just replacing the file with the bad rules with a file that has good rules in it.

Using app notifications for marketing could kill your app

I’ve noticed a recent trend in which app development companies misunderstand the purpose of app notifications and try to use them as a marketing tool.

App notifications are a means for your app to communicate timely information to your user that your *user* thinks is important and that is part of the service provided by your app. For example, the Mail app uses notifications to show that a new email message has arrived. Uber uses notifications to show that your car has arrived. Starbucks uses notifications to show an update to your account balance.

Never ever make the mistake of thinking that a notification is in any way similar to your email list. A single marketing notification could, in fact, shut down your company. Imagine this sequence:
* User’s at lunch talking with a friend
* Her iPhone pings
* Expecting something important (to her), she pulls her phone out of her purse
* A notification says “Schedule a ride with Lyft!”
* Seeing the WTF look on her friend’s face, her friend asks “what’s up”?
* Lyft’s soon-to-be-ex user says “stupid notification from Lyft saying I can schedule a ride with them. Duh, that’s why I installed the app.”
* Soon-to-be-Lyft-user’s friend says “huh, I use Uber. They don’t spam.”
* Ex-Lyft user turns off notifications for Lyft to prevent notification spam. Or, just deletes the app and installs Uber.

A non-useful notification is likely to get users to turn notifications completely off for your app. I just did this for “Curbside”, who decided to notify me that I could place an order through them (duh, that’s why I installed the app), and for Lyft, because it notified me randomly that I could book a ride in their app (albeit in a different context, and gender, than in the story above).

Even if your app sends useful notifications (both Curbside and Lyft rely heavily on them as part of their services), a single marketing notification can get your app notifications turned off. That, of course, means that 1) if the user does use your app again, they’ll miss important notifications, and 2) they may have complaints because they didn’t receive a required notification (eg their order is ready or their driver is outside). More likely though, if they have to choose between notification spam or using another app, they just won’t use your app. If your business relies on that app, that marketing notification may have just shut down your company.

Think very very carefully about the notifications you send, and make sure they’re only a necessary part of the service your app provides. If your marketing team is bugging you to add notifications “to increase app engagement”, send them to this article. 😉

Apple Music – Everything You’d Expect from Microsoft

Update 12/24/15: Apple’s worked out the bugs, and Apple Music is now my favorite streaming service, largely because of the integration with Siri that lets you say things like “play some Christmas songs” or “Play Take On Me” and have it play almost any song you can think of instantly. It was a lot of fun having my father in law mention an old song, ask Siri to play it, and route it to the living room speakers (via air play). That’s the kind of user experience we’ve grown to expect from Apple products. 

Original: Apple products aren’t popular because they’re original, they’re popular because they “just work”. Apparently someone forgot that when launching Apple Music.

I really wanted to like Apple Music, but every direction I turn, I hit errors. Let’s take a look at some of my favorites:

  • Turning on and running the music app just after upgrading, it displayed this beautiful screen. The colors are lovely, and it has a custom red “Ok” button.
    Apple Music - We've run into a problem.
    Apple Music Launch Screen Error
  • One of Apple Music’s interesting features is a Pandora style radio station. Select a song or artist and “start station”. This feature uses a system standard error dialog for that old-school look.
    Unable to Start Station - There was a problem starting the station. Try again later.
    Starting an Artist radio station in Apple Music.
  • One of the fun things you can try to do with Apple Music is to play videos by artists you like. When looking at an artist’s page, Apple Music will recommend top videos. Viewing the latest Carly Rae Jepsen video on my Mac Mini shows this lovely dialog. Again, it’s a system standard dialog, but it does feature the new iTunes app logo in the upper left corner. Among the dialog’s features are handy recommendations about how you might convince iTunes to let you view the video, and a check box to make future videos fail to play silently for added confusion in the future.
    iTunes HDCP error message
    iTunes HDCP error message

As for Apple Music’s other features, the iOS app is excellent at crashing in the middle of a video or song. If you get a video to play on the iPad, it displays with a light gray border that you cannot remove. I did manage to get an artist radio station to play once, and Apple Music quickly veered away from anything I’d want to hear. The “You” playlists I’ve tried had about one interesting song in ten.

So, aside from the lovely types of error dialogs, Google Music’s multi-device service seems to be the best for having your music available everywhere, and I’d stick with Spotify and Pandora for streaming and radio services.

Beware of

If you’re considering signing up on, or moving your account over, be wary. As for me, I’m not planning on signing up on Upwork again. recently absorbed I used to hire some people from Elance, so I clicked the button to move my account over.

First, they got my name wrong and wouldn’t let me change it without an ID verification (it had the name of a previous employee for my now ex-company under which I’d set up the account). After an email with a support rep I decided to close the ex-company’s account and create a new account for myself.

After closing the account, I received this email (with the name of my old company, not “[company name]”):

We wanted to let you know that Upwork has closed or suspended the account of [company name], a freelancer you work with.
Unfortunately this means that your contract with them has been terminated as well.
While we can’t discuss why the account was closed, please be assured that our focus is to ensure a safe and trusted workplace for you. We apologize for any inconvenience this may cause. If you have questions feel free to contact Customer Support.

I’m assuming that Upwork intended this message for my vendors and customers, not for me. Would you want your customers getting that email? I wouldn’t. I won’t make a new account on there – if I did need to use it, I certainly wouldn’t want to add any customers or vendors as potential targets for slanderous email.

How to compose a message without seeing your inbox in Apple Mail

Of course you’ve read all the email advice from David Sparks and LifeHacker. So, I’m assuming you’ve turned off email notifications and badges and set Mail to only fetch manually.

But, how do you compose an email message without getting ambushed by your inbox appearing?

I use this trick in Apple Mail to keep my in boxes accessible but hidden, and compose a new message without having to see my inbox:

  • Open Mail *
  • Select an empty mail folder ** (I add one to my favorites bar so command-8 selects it. On a related note, I close the email sidebar and have my frequently accessed inbox and archive folders in the favorites bar).
  • Minimize the Mail window (command-M or click the yellow button). This puts it down in the right side of your dock (or bottom if your dock’s on the side). This means when you bring Mail to the front, your in boxes will stay minimized. No ambush.
  • To compose a new message, click-hold on the Mail icon (the app, not your inbox) in your Dock and select “Compose Message”. You get a new message window, and no in boxes. Compose (body, subject, then address, of course, per MacSparky’s excellent advice) and send.

* At the time of this writing, I’m using MacOS 10.10.4 with Mail 8.2.
** This prevents inbox ambush if you do accidentally un-minimize your mail reader window.