MySQL Custom PS1 via MySQL configuration file

Example

In mysqld.cnf or equivalent:

[mysql]
prompt = '\u@\h [\d]> '

This achieves a similar effect, without having to deal with .bashrc's.