# Javascript Node CircleCI 2.0 configuration file # # Check https://circleci.com/docs/2.0/language-javascript/ for more details # version: 2 defaults: &defaults working_directory: ~/repo docker: - image: circleci/node:10.12.0-browsers jobs: test: <<: *defaults steps: - checkout # Download and cache dependencies - restore_cache: keys: - v3-dependencies-{{ checksum "package.json" }} # fallback to using the latest cache if no exact match is found - v3-dependencies- - run: yarn install --frozen-lockfile - save_cache: paths: - node_modules key: v2-dependencies-{{ checksum "package.json" }} # run lint - run: npm run lint # run tests - run: npm run test:bs - persist_to_workspace: root: ~/repo paths: . # deploy: # <<: *defaults # steps: # # will add github as known host # - checkout # - attach_workspace: # at: ~/repo # - add_ssh_keys: # fingerprints: # - "3f:ea:54:b7:77:13:b6:cf:29:90:2b:19:bb:eb:b5:f1" # - run: # name: Authenticate with registry # command: echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> ~/.npmrc # - run: git config --global user.email circleci@circleci # - run: git config --global user.name CircleCI # - run: # name: Publish package # command: "./node_modules/.bin/lerna publish --message 'chore: release new versions' --yes" workflows: version: 2 test-deploy: jobs: - test # - deploy: # requires: # - test # filters: # branches: # only: master