Let’s say we have password stored in /root/mysql-password. Is there a way to connect to MySQL without manually coping password from that file and entering to mysql -u root -p{passowrd}?
For example something like this:
mysql -u root -p | {command} /root/mysql-password