Commit d89be35c authored by helmo's avatar helmo Committed by helmo

Issue #1694792 by helmo: Allow provision-deploy to move a site to a platform...

Issue #1694792 by helmo: Allow provision-deploy to move a site to a platform with different module paths
parent a280befe
......@@ -169,8 +169,24 @@ function drush_provision_drupal_provision_deploy() {
* Implements drush_hook_post_COMMAND().
*/
function drush_provision_drupal_post_provision_deploy() {
// Run registry-rebuild without cache-clear, if available.
if (function_exists('drush_registry_rebuild')) {
if (drush_drupal_major_version() < 8) {
provision_backend_invoke(d()->name, 'registry-rebuild --no-cache-clear');
drush_log(dt('Registry rebuilt with --no-cache-clear in drush_provision_drupal_post_provision_deploy'));
}
}
// Call the drush updatedb command.
provision_backend_invoke(d()->name, 'updatedb');
// Run registry-rebuild with cache-clear, if available.
if (function_exists('drush_registry_rebuild')) {
if (drush_drupal_major_version() < 8) {
provision_backend_invoke(d()->name, 'registry-rebuild');
drush_log(dt('Registry rebuilt without --no-cache-clear in drush_provision_drupal_post_provision_deploy'));
}
}
// We should be able to fully load Drupal now.
if (drush_bootstrap(DRUSH_BOOTSTRAP_DRUPAL_FULL)) {
drush_include_engine('drupal', 'deploy');
......
......@@ -183,6 +183,8 @@ else
msg "Not upgrading Drush, $CURRENT_DRUSH_VERSION will be used."
fi
drush dl registry_rebuild-7.x
# Fetch new version of provision.
# move existing provision
cd $HOME/.drush
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment