I once read a lazy developer is a good developer. This makes me a good developer :) I just discovered a way to do less typing with a file called my.cnf
my.cnf is a MySQL configuration file used to configure all sorts of stuff. You can use it on multiple levels for global, server and user-specific options. If you want to know what is possible with it: click here. Interesting for sure, but how did it help me get more lazy? my.cnf lets you set options for specific programs/groups within the MySQL collection. You can set options for mysqld, a specific group and for a mysql client as well. In your home dir you caneither find or create the file .my.cnf. The following rule is now in my .my.cnf:
This makes sure that when I use the mysql command, the user root is assumed. All in all this saves me typing seven characters (-u root) when starting the mysql client. I do this several times a day which nets me the time to get myself an extra cup of coffee :D Since my local root user has no password, I don't need a password, but if you need it password=something will make sure you don't need to type that as well.
En vergeet vooral niet dat het gaat om de 'user' in de [conf] sectie :) Er is ook een 'user' in de [mysqld] sectie. Die is van de server.
Eeeeh, de [client] sectie. Waarom kan ik mijn reactie nou niet wijzigen in mod_weblog?