diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 00000000..933fbe12 --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,23 @@ +version: 2 + +docker_defaults: &docker_defaults + docker: + - image: circleci/node:9.5 + +jobs: + build: + <<: *docker_defaults + steps: + - checkout + - run: + name: Dependencies + command: yarn + - run: + name: Lint + command: yarn lint + - run: + name: Flow + command: yarn flow + - run: + name: Compile + command: yarn compile diff --git a/package.json b/package.json index 05a5a3a6..32528127 100644 --- a/package.json +++ b/package.json @@ -7,9 +7,9 @@ "author": "Ledger", "license": "BSD-2-Clause", "scripts": { - "compile": "electron-webpack", + "compile": "bash ./scripts/dist.sh", "dist:dir": "yarn dist --dir -c.compression=store -c.mac.identity=null", - "dist": "bash ./scripts/dist.sh && electron-builder", + "dist": "yarn compile && electron-builder", "flow": "flow", "lint": "eslint src webpack .storybook", "postinstall": "bash ./scripts/postinstall.sh", @@ -119,7 +119,7 @@ "electron-builder": "^20.0.7", "electron-devtools-installer": "^2.2.3", "electron-webpack": "1.13.0", - "eslint": "^4.18.0", + "eslint": "^4.18.1", "eslint-config-airbnb": "^16.1.0", "eslint-config-prettier": "^2.9.0", "eslint-import-resolver-babel-module": "^4.0.0", diff --git a/scripts/dist.sh b/scripts/dist.sh index d0cb46ca..4ea6ba0f 100755 --- a/scripts/dist.sh +++ b/scripts/dist.sh @@ -2,4 +2,4 @@ rm -rf dist && NODE_ENV=production webpack --config webpack/internals.config.js && -yarn compile +electron-webpack diff --git a/yarn.lock b/yarn.lock index a13fdf07..5cafff98 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3803,9 +3803,9 @@ eslint-visitor-keys@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" -eslint@^4.18.0: - version "4.18.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.18.0.tgz#ebd0ba795af6dc59aa5cee17938160af5950e051" +eslint@^4.18.1: + version "4.18.1" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.18.1.tgz#b9138440cb1e98b2f44a0d578c6ecf8eae6150b0" dependencies: ajv "^5.3.0" babel-code-frame "^6.22.0"