UNPKG

2.82 kBYAMLView Raw
1step-env: &step-env
2 run:
3 # prevent Wine popup dialogs about installing additional packages
4 name: Setup Environment Variables
5 command: |
6 echo 'export WINEDLLOVERRIDES="mscoree,mshtml="' >> $BASH_ENV
7 echo 'export WINEDEBUG="-all"' >> $BASH_ENV
8
9step-restore-brew-cache: &step-restore-brew-cache
10 restore_cache:
11 name: Restoring Homebrew cache
12 paths:
13 - /usr/local/Homebrew
14 keys:
15 - v1-brew-cache-{{ arch }}
16
17step-save-brew-cache: &step-save-brew-cache
18 save_cache:
19 name: Persisting Homebrew cache
20 paths:
21 - /usr/local/Homebrew
22 key: v1-brew-cache-{{ arch }}
23
24step-restore-cache: &step-restore-cache
25 restore_cache:
26 keys:
27 - v1-dependencies-{{ arch }}-{{ checksum "yarn.lock" }}
28 - v1-dependencies-{{ arch }}-
29
30step-save-cache: &step-save-cache
31 save_cache:
32 paths:
33 - node_modules
34 key: v1-dependencies-{{ arch }}-{{ checksum "yarn.lock" }}
35
36step-install-os-dependencies: &step-install-os-dependencies
37 run:
38 name: Install OS Dependencies
39 command: |
40 case "$(uname)" in
41 Linux)
42 sudo dpkg --add-architecture i386
43 sudo apt-get -qq update
44 sudo apt-get install --no-install-recommends -y wine64 wine32 wine mono-devel
45 wine64 hostname
46 ;;
47 Darwin)
48 brew install --cask xquartz wine-stable
49 brew install mono
50 wine64 hostname
51 ;;
52 esac
53
54steps-linux-win: &steps-linux-win
55 steps:
56 - *step-env
57 - *step-install-os-dependencies
58 - checkout
59 - *step-restore-cache
60 - run: yarn
61 - *step-save-cache
62 - run: yarn test
63
64steps-mac: &steps-mac
65 steps:
66 - *step-env
67 - *step-restore-brew-cache
68 - *step-install-os-dependencies
69 - *step-save-brew-cache
70 - checkout
71 - *step-restore-cache
72 - run: yarn
73 - *step-save-cache
74 - run: yarn test
75
76version: 2.1
77orbs:
78 win: circleci/windows@1.0.0
79jobs:
80 test-linux:
81 docker:
82 - image: circleci/node@sha256:44c6136b6b55003fa12321aa1eb790a5a6482edb461227cb56daf488178d04dc
83 <<: *steps-linux-win
84 test-mac:
85 macos:
86 xcode: "11.1.0"
87 <<: *steps-mac
88 test-windows:
89 executor:
90 name: win/vs2019
91 shell: bash.exe
92 <<: *steps-linux-win
93
94 release:
95 docker:
96 - image: circleci/node:10.15
97 steps:
98 - checkout
99 - *step-restore-cache
100 - run: yarn
101 - run: npx semantic-release
102workflows:
103 version: 2
104 test_and_release:
105 # Run the test jobs first, then the release only when all the test jobs are successful
106 jobs:
107 # - test-linux
108 - test-mac
109 - test-windows
110 - release:
111 requires:
112 # - test-linux
113 - test-mac
114 - test-windows
115 filters:
116 branches:
117 only:
118 - master