Sign up ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

From a Mac OS command line, I'm looking for a command that will read my address book card and print my email address to stdout.

Doing it via an osascript command would be fine.

share|improve this question

1 Answer 1

What you are looking for is contacts.

The utility contacts gives you access to view and search all your records in the AddressBook database.

Without further ado, here are a few examples:

$ contacts -h
usage: contacts [-hHsmnlS] [-f format] [search]
      -h displays help (this)
      -H suppress header
      -s sort list
      -m show me
      -n displays note below each record
      -l loose formatting (doesn't truncate record values)
      -S strict formatting (doesn't add space between columns)
      -f accepts a format string (see man page)

displays contacts from the AddressBook database

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.