Skip to content

Instantly share code, notes, and snippets.

@bigdawggi
Created March 25, 2015 23:52
Show Gist options
  • Save bigdawggi/a4eb094faa213c3a1297 to your computer and use it in GitHub Desktop.
Save bigdawggi/a4eb094faa213c3a1297 to your computer and use it in GitHub Desktop.
Codeship Custom Deploy Script for WPEngine
# You must set up two environment variables:
# repoSlug = slug for WP Engine repository
# themeDir = path from the top of the repository, to the theme directory
git remote add production git@git.wpengine.com:production/${repoSlug}.git
git remote add staging git@git.wpengine.com:staging/${repoSlug}.git
cd ${themeDir}
npm install
npm install -g bower
bower install
gulp build
git config --global user.email "codeship-deploy-bot@example.com"
git config --global user.name "Codeship Deploy Bot"
git config push.default current
git checkout -b deploy
git add public
git commit -m "DEPLOYMENT - public folder build"
git push -f staging deploy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment