Re interacting with MySQL, not sure if this is really answering your question but I've found SequelAce covers everything I need to do, other than automated scripting. But of course everyone's use-cases are different so you may need more command line mysql client stuff than me.
Thanks for posting your solution above. I do have quite a few pretty complex automated zsh scripts involving mysql, so I just checked a few and remembered I used an external credentials file, which contains all the access info. Here's an example:
A sample mysql call in a bash/zsh script:
mysql --defaults-extra-file=../mysql-credentials.dev -e "CREATE DATABASE my_database"
mysql-credentials.dev file looks like this:
Of course that's a bit of a pain if you're just doing stuff ad-hoc on the command line. I'm hoping to have mysql automatically pick up the correct configuration as part of the chosen stack's terminal preset.