Skip to content

Instantly share code, notes, and snippets.

@wimvds
Last active December 15, 2015 17:59
Show Gist options
  • Save wimvds/5300543 to your computer and use it in GitHub Desktop.
Save wimvds/5300543 to your computer and use it in GitHub Desktop.
Move all Drupal modules in sites/all/modules to sites/all/modules/contrib
#!/bin/bash
# First install registry_rebuild : drush dl registry_rebuild
# Execute the following :
for dir in */; do dir=${dir%*/}; if [ "custom" != "${dir}" -a "contrib" != "${dir}" ]; then mv ${dir} contrib/${dir}; fi; done
# Run registry_rebuild and clear all caches : drush rr && drush cc all
# Fingers crossed...
# To update your git repo afterwards, just use : git add -u
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment