Skip to content

Instantly share code, notes, and snippets.

@jonathanmoore
Created June 13, 2014 21:00
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 jonathanmoore/faf90b9297939c550663 to your computer and use it in GitHub Desktop.
Save jonathanmoore/faf90b9297939c550663 to your computer and use it in GitHub Desktop.
Gulp Task for building to a new branch
gulp.task 'deploy', shell.task [
'git checkout master'
'git branch -D dist'
'git stash'
'git checkout -b dist'
'rm .gitignore'
'git add .gitignore --all'
'gulp build',
'git add public'
'git commit -m "build for release"'
'git push heroku dist:master --force'
'git checkout master'
'git branch -D dist'
'git stash pop'
'echo "Deployed."'
'heroku open'
], ignoreErrors: true
// public/components/bower
// git checkout dist -- public/components/bower
// git reset
@christophwolff
Copy link

What does
'rm .gitignore' 'git add .gitignore --all'
do? Dont really get it becaus you are deleting the .gitignore file. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment