MacOS – How to delete imap email accounts without opening Mail

macosmail.app

After Yosemite update Mail crashes as soon as I open with an 'Absolute path' error. I've tried all the usual things

  • removing the Envelop Index (hangs without crashing)
  • turning off all the mail accounts in System Preferences

The error message indicates its an issue with some IMAP account but I still have a POP account that I need to keep, so I can't just delete the ~/Library/Mail folder. Is there a way to delete the IMAP accounts by editing the plist files.


Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Absolute path passed into -[MFIMAPAccount mailboxForRelativePath:isFilesystemPath:create:]: //Archive'
abort() called

Best Answer

Go to Settings -> Internet Accounts -> Delete / Disable your email.