Skip to content
This repository has been archived by the owner on Jan 5, 2023. It is now read-only.

Commit

Permalink
ADD github action (#68)
Browse files Browse the repository at this point in the history
ADD github action
  • Loading branch information
ndelangen authored Oct 19, 2019
2 parents 68c799f + b930510 commit a25560a
Show file tree
Hide file tree
Showing 4 changed files with 1,254 additions and 21 deletions.
26 changes: 26 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
version: 2

jobs:
build:
docker:
- image: circleci/node:10
working_directory: ~/repo
steps:
- checkout
- restore_cache:
keys:
- v1-dependencies-{{ checksum "package.json" }}
- v1-dependencies-
- run: yarn install
- save_cache:
paths:
- node_modules
key: v1-dependencies-{{ checksum "package.json" }}

- run: yarn compile

workflows:
version: 2
test:
jobs:
- build
21 changes: 21 additions & 0 deletions .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: "Chromatic"
on:
pull_request:

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- run: |
yarn
- run: |
yarn compile
- run: |
yarn build-storybook
- uses: chromaui/action@v1
with:
appCode: ${{ secrets.CHROMATIC_APP_CODE }}
token: ${{ secrets.GITHUB_TOKEN }}
storybookBuildDir: storybook-static

6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"clean": "rimraf ./dist",
"compile": "babel ./src --out-dir ./dist",
"prepublish": "npm run clean && npm run compile",
"build-storybook": "build-storybook",
"storybook": "start-storybook -p 9010",
"test": "jest"
},
Expand All @@ -28,8 +29,8 @@
"@storybook/client-logger": "^5.0.0",
"@storybook/react": "^5.0.0",
"babel-loader": "^8.0.4",
"css-loader": "^3.1.0",
"core-js": "^3.0.1",
"css-loader": "^3.1.0",
"eslint-config-taller": "^2.0.0",
"eslint-plugin-flowtype": "^3.5.1",
"jest": "^24.7.1",
Expand All @@ -44,5 +45,8 @@
"@storybook/react": "^5.0.0",
"babel-plugin-react-docgen": "^2.0.0",
"react": ">=15.0.0 || ^16.0.0"
},
"dependencies": {
"storybook-chromatic": "^3.0.3"
}
}
Loading

0 comments on commit a25560a

Please sign in to comment.