Searching for WordPress installations


If you have multiple WordPress installations on your web server, you may occasionally have to change the settings in the configuration of all of your sites. The following command allows you to find all installations from a starting directory.

find ./ -type f -name 'wp-config.php'

Personally I like to use the text editor nano when I do stuff like that, and nano can open multiple files one after the other with one command. So we can rewrite the previous command to this one to open all files in sequence:

nano $(find ./ -type f -name 'wp-config.php' -print0 | tr '\0' '\040')