publish 567 B

123456789101112131415161718192021
  1. echo -e "\033[0;33;1mPublish start."
  2. echo -e "\033[0;33;1m> Checking out gh-pages...\033[0m"
  3. git branch -D gh-pages -q
  4. git checkout -q -b gh-pages
  5. echo -e "\033[0;33;1m> Delete server branch...\033[0m"
  6. git push origin :gh-pages -q
  7. echo -e "\033[0;33;1m> Building dist js files...\033[0m"
  8. grunt -q > GRUNT_OUTPUT
  9. rm -f GRUNT_OUTPUT
  10. echo -e "\033[0;33;1m> Commit dist js files...\033[0m"
  11. git add dist
  12. git commit -qm "publish"
  13. echo -e "\033[0;33;1m> Pusing to git...\033[0m"
  14. git push -q origin gh-pages
  15. git checkout -q dev
  16. echo -e "\033[0;33;1mPublish done.\033[0m"