Password-store keeps your passwords (or any other sensitive information) saved in GnuPG encrypted files organized in ~/.password-store. For more information about GPG, consult the GNU Privacy Handbook.
To get started, install pass and generate a keypair.
$ brew install pass
$ gpg --gen-key
$ gpg --list-keys