Updating drupal using the standard instructions is very time consuming - have to turn off modules/themes, update settings, reinstall modules/themes.
But many users find that for many updates to the same major release, for example, 4.7.x series, simpler upgrades can work - official Drupal install instructions do not allow this, nor is the structure of Drupal folder structure a help, since user installed modules/themes are in the same folder as the drupal files (would be good to have these separate), and no easy way exists to try out a new release before switching to it on a running site.
Given all that, here's how an update can be done fast - very important to read the UPGRADE.txt Drupal document first, and do all backups, and be ready to restore quickly if things don't work.
No guarantees on this method, but it has been known to work.
Assume that old drupal install is in current/ and new one is new/
- extract the new drupal release, into the new/ directory.
- copy over all the new files and directories from your current install, to this new/ directory. See script "update.sh" below which does this.
- update the config files - sites/default
- login to current drupal as admin
- backup: rename current/ to current.backup/
- rename new/ dir to current/
- run current/update.php from drupal and on success, log off the admin user. and test it out
And here's the update.sh script - edit $OLD variable, run this from inside the new/ directory, and redirect output to update.run, take a look at the update.run commands, and then run the commands in update.run:
#!/bin/sh
OLD="current/"
echo "# Current Directory: " `pwd`
for i in `cd $OLD; find . -print`
do
if [ ! -e "$i" ]
then
if [ -d "$OLD/$i" ]
then
echo mkdir -p -v "$i"
fi
if [ -f "$OLD/$i" ]
then
echo cp -p -v -i --reply=no "$OLD/$i" `dirname "$i"`
fi
fi
done