Skip to content

Instantly share code, notes, and snippets.

@meriadec
Created July 17, 2018 15:20
Show Gist options
  • Save meriadec/10f7c77400baa3f6803cf0306e51fe4e to your computer and use it in GitHub Desktop.
Save meriadec/10f7c77400baa3f6803cf0306e51fe4e to your computer and use it in GitHub Desktop.
version: 2
defaults: &defaults
working_directory: ~/ledger-live-desktop
docker:
- image: circleci/node:8.11.3-stretch-browsers
jobs:
setup:
<<: *defaults
steps:
- checkout
- restore_cache:
keys:
- v7-yarn-packages-{{ checksum "yarn.lock" }}
- run: yarn install
- save_cache:
key: v7-yarn-packages-{{ checksum "yarn.lock" }}
paths:
- node_modules
lint:
<<: *defaults
steps:
- checkout
- restore_cache:
keys:
- v7-yarn-packages-{{ checksum "yarn.lock" }}
- run: yarn install
- run: yarn lint
prettier:
<<: *defaults
steps:
- checkout
- restore_cache:
keys:
- v7-yarn-packages-{{ checksum "yarn.lock" }}
- run: yarn install
- run: ./node_modules/.bin/prettier -l "{src,webpack,.storybook,static/i18n}/**/*.js"
flow:
<<: *defaults
steps:
- checkout
- restore_cache:
keys:
- v7-yarn-packages-{{ checksum "yarn.lock" }}
- run: yarn install
- run: yarn flow --quiet
release_if_tag:
<<: *defaults
steps:
- checkout
- restore_cache:
keys:
- v7-yarn-packages-{{ checksum "yarn.lock" }}
- run: yarn install
- run: yarn release
workflows:
version: 2
default:
jobs:
- setup
- lint:
requires:
- setup
- prettier:
requires:
- setup
- flow:
requires:
- setup
- release_if_tag:
requires:
- lint
- prettier
- flow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment