I think I'm looking at awk vs PHP vs Perl vs cut. Maybe.
I want to look at
wp-config.php and look at these lines:
define('DB_NAME', 'mydb'); define('DB_USER', 'myuser'); define('DB_PASSWORD', 'xx');
And pull out the strings "mydb" and "myuser" and the password, so I can do something with it, e.g.:
#!/bin/sh ..insert magical code here to store strings into DBNAME, USERNAME, PASSWORD... mysqldump -u $USERNAME -p$PASSWORD $DBNAME > /tmp/blah.sql