-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e86ebbc
commit 9ef1ece
Showing
2 changed files
with
104 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
version: 2.1 | ||
|
||
defaults: &defaults | ||
parameters: | ||
react-dist-tag: | ||
description: The dist-tag of react to be used | ||
type: string | ||
default: stable | ||
environment: | ||
# expose it globally otherwise we have to thread it from each job to the install command | ||
REACT_DIST_TAG: << parameters.react-dist-tag >> | ||
working_directory: /tmp/material-ui-x | ||
docker: | ||
- image: circleci/node:10 | ||
# CircleCI has disabled the cache across forks for security reasons. | ||
# Following their official statement, it was a quick solution, they | ||
# are working on providing this feature back with appropriate security measures. | ||
# https://discuss.circleci.com/t/saving-cache-stopped-working-warning-skipping-this-step-disabled-in-configuration/24423/21 | ||
# | ||
# restore_repo: &restore_repo | ||
# restore_cache: | ||
# key: v1-repo-{{ .Branch }}-{{ .Revision }} | ||
|
||
commands: | ||
install_js: | ||
steps: | ||
- run: | ||
name: View install environment | ||
command: | | ||
node --version | ||
yarn --version | ||
- restore_cache: | ||
keys: | ||
- v2-yarn-sha-{{ checksum "yarn.lock" }} | ||
- v2-yarn-sha- | ||
- run: | ||
name: Install js dependencies | ||
command: yarn | ||
|
||
jobs: | ||
checkout: | ||
<<: *defaults | ||
steps: | ||
- checkout | ||
- install_js | ||
- run: | ||
name: Should not have any git not staged | ||
command: git diff --exit-code | ||
- save_cache: | ||
key: v2-yarn-sha-{{ checksum "yarn.lock" }} | ||
paths: | ||
- ~/.cache/yarn/v4 | ||
test_static: | ||
<<: *defaults | ||
steps: | ||
- checkout | ||
- install_js | ||
- run: | ||
name: '`yarn prettier` changes committed?' | ||
command: yarn prettier check-changed | ||
- run: | ||
name: Lint | ||
command: yarn lint:ci | ||
workflows: | ||
version: 2 | ||
pipeline: | ||
jobs: | ||
- checkout | ||
- test_static: | ||
requires: | ||
- checkout |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters