Skip to content

Instantly share code, notes, and snippets.

@helior
Created January 1, 2012 01:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save helior/1545860 to your computer and use it in GitHub Desktop.
Save helior/1545860 to your computer and use it in GitHub Desktop.
Rebuild script for Drupal makefiles – detects override.make file and runs that instead. override.make should: be ignored by Git; include original makefile; reference additional/alternative/null repositories and/or permissions (e.g. helior@git.drupal.org:p
#!/bin/bash
OVERRIDEMAKEFILE="override.make"
COMMONMAKEFILE="$(basename `pwd`).make"
# If the override make file exists, use it...
if [ -e $OVERRIDEMAKEFILE ]; then
MAKEFILE=$OVERRIDEMAKEFILE
# ... otherwise use the common makefile
else
MAKEFILE=$COMMONMAKEFILE
fi
echo "Using $MAKEFILE......."
drush make --yes --no-core --working-copy --contrib-destination=. ./$MAKEFILE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment