Updating the updateVersions to use a class internally. It can still be called from the cli, but this will make it more flexible for other scripts to use.
Changing the way $_changed is used and hence its name to $_changes.