Skip to content

Commit

Permalink
chore: refactor ci workflow so that lint depends on compile
Browse files Browse the repository at this point in the history
  • Loading branch information
spiltcoffee committed Mar 9, 2019
1 parent b158774 commit 4a1e379
Showing 1 changed file with 20 additions and 16 deletions.
36 changes: 20 additions & 16 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- packages/@postdfm/dfm2ast/node_modules
key: v1-dependencies-{{ checksum "yarn.lock" }}

lint:
compile:
executor: node-executor
steps:
- checkout
Expand All @@ -39,9 +39,15 @@ jobs:
- v1-dependencies-{{ checksum "yarn.lock" }}
- v1-dependencies-

- run: yarn lint:check
- run: yarn compile

format:
- persist_to_workspace:
root: packages
paths:
- ./postdfm/dist
- ./@postdfm/dfm2ast/dist

lint:
executor: node-executor
steps:
- checkout
Expand All @@ -50,9 +56,12 @@ jobs:
- v1-dependencies-{{ checksum "yarn.lock" }}
- v1-dependencies-

- run: yarn format:check
- attach_workspace:
at: ~/repo/packages

compile:
- run: yarn lint:check

format:
executor: node-executor
steps:
- checkout
Expand All @@ -61,13 +70,8 @@ jobs:
- v1-dependencies-{{ checksum "yarn.lock" }}
- v1-dependencies-

- run: yarn compile
- run: yarn format:check

- persist_to_workspace:
root: packages
paths:
- ./postdfm/dist
- ./@postdfm/dfm2ast/dist
test:
executor: node-executor
steps:
Expand Down Expand Up @@ -104,18 +108,18 @@ workflows:
ci:
jobs:
- bootstrap
- lint:
- compile:
requires:
- bootstrap
- lint:
requires:
- compile
- format:
requires:
- lint
- compile:
requires:
- format
- test:
requires:
- compile
- format
- release:
requires:
- test

0 comments on commit 4a1e379

Please sign in to comment.