Some while back Drupal changed the structure of core upgrade files so that they unzip/untar into a directory with the version number: e.g. drupal-7.31/
While this is safer (the tar operation doesn't overwrite the site), I'm then having trouble moving all the files to their correct locations: I keep getting told that mv can't move a non-empty subdirectory (or is it that it can't overwrite files in a non-empty subdirectory?

So what are the correct options to add to mv drupal-7.31/* ./ ?

Comments

John_B’s picture

I googled for an answer and found someone suggesting rsync. Why not? http://askubuntu.com/questions/269775/mv-directory-not-empty.

Or you can do

cd drupal-7.31
cp -pr * ..
cd ..
rm -r drupal-7.31

(pipe in yes | if the server asks you to confirm every overwrite)

(be careful not to overwrite /sites/ or robots.txt; this command will probably not overwrite .htaccess or other hidden files)

rsync is more elegant.

Digit Professionals specialising in Drupal, WordPress & CiviCRM support for publishers in non-profit and related sectors