@samitouri / QOS-React / commits / a2b6b6b206

Migrate to CircleCI2.0 and Add AppVeyor for master-only branch (#11605)

* add appveyor config file * migrate circleci 1.0 to circleci 2.0 * remove upload step in favour of #11666

Raphael Amorim committed Nov 28, 2017 at 12:39 UTC a2b6b6b206f7bdb41bffa7cff7f6b8a868f1a207
3 files changed +87 -34
.circleci/config.yml new
+50
@@ -0,0 +1,50 @@
1 +version: 2
2 +jobs:
3 + build:
4 +
5 + docker:
6 + - image: circleci/node:8
7 +
8 + environment:
9 + TZ: /usr/share/zoneinfo/America/Los_Angeles
10 + YARN_VERSION: 1.2.1
11 + TRAVIS_REPO_SLUG: facebook/react
12 +
13 + parallelism: 4
14 +
15 + steps:
16 + - checkout
17 +
18 + - run: echo $CIRCLE_COMPARE_URL | cut -d/ -f7
19 +
20 + - run:
21 + name: Install Yarn
22 + command: |
23 + if [[ ! -e ~/.yarn/bin/yarn || $(yarn --version) != "${YARN_VERSION}" ]]; then
24 + curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version $YARN_VERSION
25 + fi
26 +
27 + - restore_cache:
28 + name: Restore node_modules cache
29 + keys:
30 + - v1-node-{{ arch }}-{{ .Branch }}-{{ checksum "yarn.lock" }}
31 + - v1-node-{{ arch }}-{{ .Branch }}-
32 + - v1-node-{{ arch }}-
33 +
34 + - run:
35 + name: Nodejs Version
36 + command: node --version
37 +
38 + - run:
39 + name: Install Packages
40 + command: yarn install
41 +
42 + - run:
43 + name: Test Packages
44 + command: ./scripts/circleci/test_entry_point.sh
45 +
46 + - save_cache:
47 + name: Save node_modules cache
48 + key: v1-node-{{ arch }}-{{ .Branch }}-{{ checksum "yarn.lock" }}
49 + paths:
50 + - node_modules
appveyor.yml new
+37
@@ -0,0 +1,37 @@
1 +image: Visual Studio 2017
2 +
3 +# Fix line endings in Windows. (runs before repo cloning)
4 +init:
5 + - git config --global core.autocrlf input
6 +
7 +environment:
8 + matrix:
9 + - nodejs_version: 8
10 +
11 +# Finish on first failed build
12 +matrix:
13 + fast_finish: true
14 +
15 +platform:
16 + - x64
17 +
18 +branches:
19 + only:
20 + - master
21 +
22 +# Disable Visual Studio build and deploy
23 +build: off
24 +deploy: off
25 +
26 +install:
27 + - ps: Install-Product node $env:nodejs_version $env:platform
28 + - yarn install
29 +
30 +test_script:
31 + - node --version
32 + - yarn build
33 + - yarn test
34 +
35 +cache:
36 + - node_modules
37 + - "%LOCALAPPDATA%/Yarn"
circle.yml deleted
-34
@@ -1,34 +0,0 @@
1 ----
2 -machine:
3 - timezone: America/Los_Angeles
4 - node:
5 - version: 8
6 - ruby:
7 - version: 2.2.3
8 - environment:
9 - TRAVIS_REPO_SLUG: facebook/react
10 - YARN_VERSION: 1.2.1
11 - PATH: "${PATH}:${HOME}/.yarn/bin"
12 -
13 -dependencies:
14 - pre:
15 - # This is equivalent to $TRAVIS_COMMIT_RANGE
16 - - echo $CIRCLE_COMPARE_URL | cut -d/ -f7
17 - # install yarn if it's not already installed
18 - - |
19 - if [[ ! -e ~/.yarn/bin/yarn || $(yarn --version) != "${YARN_VERSION}" ]]; then
20 - curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version $YARN_VERSION
21 - fi
22 - override:
23 - - yarn install
24 - - scripts/circleci/set_up_github_keys.sh
25 - post:
26 - # - npm ls --depth=0
27 - cache_directories:
28 - - ~/.yarn
29 - - ~/.yarn-cache
30 -
31 -test:
32 - override:
33 - - ./scripts/circleci/test_entry_point.sh:
34 - parallel: true