regexper-static/.circleci/config.yml

52 lines
1.0 KiB
YAML

version: 2
jobs:
build_deploy:
docker:
- image: circleci/node:latest
working_directory: ~/repo
steps:
- checkout
# Download and cache dependencies
- restore_cache:
keys:
- v1-dependencies-{{ checksum "package.json" }}
# fallback to using the latest cache if no exact match is found
- v1-dependencies-
- run: yarn install
- save_cache:
paths:
- node_modules
key: v1-dependencies-{{ checksum "package.json" }}
- run: yarn test
- run: yarn build
# TODO: Deploy to preview.regexper.com
workflows:
version: 2
preview:
jobs:
- build_deploy:
context: preview-context
filters:
tags:
ignore: /.*/
branches:
only: /.*/
prod:
jobs:
- build_deploy:
context: prod-context
filters:
tags:
only: /.*/
branches:
ignore: /.*/