Tag: comics
sudo -u
by Nick on Jun.11, 2009, under News, UNIX 101
Sometimes, especially on X.X upgrades, WordPress Automatic Update does not work.
Oh, it claims to work. But it doesn’t. So you have to upgrade manually. Now, a manual upgrade is trivial in WordPress. Just download the zip (or gzipped tar,) unpack it, copy the files, go to the admin interface, and click two buttons.
But what if you have multiple users, who have WordPress in their home directories? Use sudo!
Sudo is a tool that administrators can use to execute commands as root. However, you can also the -u parameter to execute a command as another user.
So, if I put WordPress in a neutral folder, then I can simply do this:
>sudo -u username cp -r wordpress/* /home/username/www/example.com/
Voila! Nice and easy.
I should script this…

