Skip to content

Instantly share code, notes, and snippets.

@nekonenene
Last active May 23, 2019 19:56
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 nekonenene/13ed5b0acf830f29518c9f50850ce918 to your computer and use it in GitHub Desktop.
Save nekonenene/13ed5b0acf830f29518c9f50850ce918 to your computer and use it in GitHub Desktop.
ビルドしたものだけを gh-pages に push する(ブログ公開用) https://nekonenene.hatenablog.com/entry/2016/11/02/040706
general:
branches:
ignore:
- gh-pages
machine:
timezone: Asia/Tokyo
node:
version: v6.1.0
dependencies:
pre:
- rm -rf node_modules
override:
- npm install
test:
override:
- npm run test
deployment:
deploy:
branch: master
commands:
- npm run build
- rm -rf src
- cp -Rf build/. ./
- git config --global user.name "CircleCI"
- git config --global user.email "circleci@gh-pages.com"
- git add .
- git commit -m "Publish [ci skip]"
- git checkout -B gh-pages
- git push -u origin gh-pages --force
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment