1
0
Fork 0
docsearch/scripts/docs/update-website
Vincent Voyer 28159c2801 chore(docs): precise how to run project (#200)
Remove redundant messages in README and CONTRIBUTING. Move GIF to
bootstrap.

Allow netlify deploys to work.
2017-10-17 17:02:45 +02:00

27 lines
527 B
Bash
Executable file

#! /usr/bin/env bash
set -ev # exit when error
if [ -z $TRAVIS_BRANCH ]; then
currentBranch=`git rev-parse --abbrev-ref HEAD`
else
currentBranch=$TRAVIS_BRANCH
fi
if [ $currentBranch != 'master' ]; then
printf "update-website: You must be on master"
exit 1
fi
VERSION=`cat package.json | json version`
set -e # exit when error
printf "\nPublish website to gh-pages\n"
cd docs
bundle install
rm -rf _site
JEKYLL_ENV=production VERSION=${VERSION} bundle exec jekyll build
cd ..
babel-node scripts/docs/gh-pages.js