Skip to content

Commit 670f00f

Browse files
authored
Upgrade versions (#7)
Adds prebuilt binaries for Electron 1.8 and 2.0, as well as Node 10, for MacOS, Linux and Windows.
1 parent 7e72082 commit 670f00f

5 files changed

Lines changed: 411 additions & 117 deletions

File tree

.circleci/config.yml

Lines changed: 101 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,101 +1,154 @@
1-
version: 2
2-
jobs:
3-
build-node-common: &common-build
4-
docker:
5-
# The docker section here is not used, but required
6-
- image: circleci/node:8.9.3
7-
1+
aliases:
2+
- &publish-command
3+
name: Publish
4+
command: |
5+
COMMIT_MESSAGE=`git log --format=%s -n 1 $CIRCLE_SHA1`
6+
./node_modules/.bin/node-pre-gyp rebuild package testpackage $PRE_GYP_ARGS
7+
if [[ ${COMMIT_MESSAGE} =~ "[publish binary]" ]]; then
8+
./node_modules/.bin/node-pre-gyp package testpackage $PRE_GYP_ARGS
9+
./node_modules/.bin/node-pre-gyp publish $PRE_GYP_ARGS
10+
else
11+
echo "Not a tagged build - not publishing"
12+
fi
13+
14+
- &common-build
815
working_directory: ~/repo
9-
1016
steps:
1117
- checkout
1218
# Install git-lfs (not part of the standard Docker images)
1319
- run: curl -sSL https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | sudo bash && sudo apt-get update && sudo apt-get install -y git-lfs && git-lfs install --force && git-lfs pull
1420
- run: npm install --build-from-source
1521

1622
- run: npm run test
17-
- run: &publish-command
18-
name: Publish
19-
command: |
20-
COMMIT_MESSAGE=`git log --format=%s -n 1 $CIRCLE_SHA1`
21-
if [[ ${COMMIT_MESSAGE} =~ "[publish binary]" ]]; then
22-
./node_modules/.bin/node-pre-gyp package testpackage $PRE_GYP_ARGS
23-
./node_modules/.bin/node-pre-gyp publish $PRE_GYP_ARGS
24-
else
25-
echo "Not a tagged build - not publishing"
26-
fi
23+
- run: *publish-command
2724

2825

29-
build-9.3.0:
30-
<<: *common-build
26+
- &common-electron-linux
3127
docker:
32-
- image: circleci/node:9.3.0
33-
34-
build-8.9.3:
35-
<<: *common-build
36-
docker:
37-
- image: circleci/node:8.9.3
38-
39-
build-7.9.0:
40-
<<: *common-build
41-
docker:
42-
- image: circleci/node:7.9.0
43-
44-
build-electron:
45-
docker:
46-
- image: circleci/node:8.9.3
28+
- image: circleci/node:10.5.0
4729

4830
working_directory: ~/repo
49-
environment:
50-
PRE_GYP_ARGS: --runtime=electron --target=1.7.9
5131

5232
steps:
5333
- checkout
5434
# Install git-lfs (not part of the standard Docker images)
5535
- run: curl -sSL https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | sudo bash && sudo apt-get update && sudo apt-get install -y git-lfs && git-lfs install --force && git-lfs pull
5636
# These are required for electron(-mocha)
57-
- run: sudo apt-get install -y libgtk2.0-0 libxtst6 libxss1 libgconf2-4 libnss3 libasound2
37+
- run: sudo apt-get install -y libgtk2.0-0 libgtk-3-dev libxtst6 libxss1 libgconf2-4 libnss3 libasound2
5838
- run: npm install --build-from-source
5939
- run: ./node_modules/.bin/electron-rebuild
6040
- run: npm run pretest
6141
- run: xvfb-run ./node_modules/.bin/electron-mocha --timeout 480000
62-
- run:
63-
<<: *publish-command
42+
- run: *publish-command
6443

65-
build-macos:
44+
45+
- &common-macos
6646
macos:
6747
xcode: "9.1.0" # Node 8.9.0
68-
6948
steps:
7049
- checkout
71-
- run: brew install git-lfs openssl
50+
- run: |
51+
export HOMEBREW_NO_AUTO_UPDATE=1
52+
brew install git-lfs openssl || true
7253
- run: git lfs install
7354
- run: git lfs pull
7455
- restore_cache:
7556
keys:
76-
- v1-dependencies-osx-{{ checksum "package-lock.json" }}
57+
- v1-dependencies-macos-{{ .Environment.CIRCLE_JOB }}-{{ checksum "package-lock.json" }}
7758
# fallback to using the latest cache if no exact match is found
78-
- v1-dependencies-osx-
59+
- v1-dependencies-macos-{{ .Environment.CIRCLE_JOB }}
7960

8061
- run: npm install --build-from-source
8162

8263
- save_cache:
8364
paths:
8465
- node_modules
85-
key: v1-dependencies-osx-{{ checksum "package-lock.json" }}
66+
key: v1-dependencies-macos-{{ .Environment.CIRCLE_JOB }}-{{ checksum "package-lock.json" }}
8667

8768
- run: npm run test
8869
- run: ./node_modules/.bin/electron-rebuild
8970
- run: ./node_modules/.bin/electron-mocha --timeout 480000
9071
- run:
9172
<<: *publish-command
9273

74+
version: 2
75+
jobs:
76+
build-10.5.0:
77+
<<: *common-build
78+
docker:
79+
- image: circleci/node:10.5.0
80+
81+
build-9.3.0:
82+
<<: *common-build
83+
docker:
84+
- image: circleci/node:9.3.0
85+
86+
build-8.9.3:
87+
<<: *common-build
88+
docker:
89+
- image: circleci/node:8.9.3
90+
91+
build-7.9.0:
92+
<<: *common-build
93+
docker:
94+
- image: circleci/node:7.9.0
95+
96+
build-electron-2.0.4:
97+
<<: *common-electron-linux
98+
environment:
99+
PRE_GYP_ARGS: --runtime=electron --target=2.0.4 --disturl=https://atom.io/download/electron
100+
101+
build-electron-1.8.6:
102+
<<: *common-electron-linux
103+
environment:
104+
PRE_GYP_ARGS: --runtime=electron --target=1.8.6 --disturl=https://atom.io/download/electron
105+
106+
build-electron-1.7.11:
107+
<<: *common-electron-linux
108+
environment:
109+
PRE_GYP_ARGS: --runtime=electron --target=1.7.9 --disturl=https://atom.io/download/electron
110+
111+
112+
build-macos-10.1.0:
113+
<<: *common-macos
114+
macos:
115+
xcode: "9.3.1" # Node 10.3.0
116+
117+
build-macos-8.9.0:
118+
<<: *common-macos
119+
macos:
120+
xcode: "9.1.0" # Node 8.9.0
121+
122+
123+
build-macos-electron-2.0.4:
124+
<<: *common-macos
125+
environment:
126+
PRE_GYP_ARGS: --runtime=electron --target=2.0.4 --disturl=https://atom.io/download/electron
127+
128+
build-macos-electron-1.8.6:
129+
<<: *common-macos
130+
environment:
131+
PRE_GYP_ARGS: --runtime=electron --target=1.8.6 --disturl=https://atom.io/download/electron
132+
133+
build-macos-electron-1.7.11:
134+
<<: *common-macos
135+
environment:
136+
PRE_GYP_ARGS: --runtime=electron --target=1.7.11 --disturl=https://atom.io/download/electron
137+
93138
workflows:
94139
version: 2
95140
build_all:
96141
jobs:
142+
- build-10.5.0
97143
- build-9.3.0
98144
- build-8.9.3
99145
- build-7.9.0
100-
- build-electron
101-
- build-macos
146+
- build-electron-2.0.4
147+
- build-electron-1.8.6
148+
- build-electron-1.7.11
149+
# Not working currently
150+
# - build-macos-10.1.0
151+
- build-macos-8.9.0
152+
- build-macos-electron-2.0.4
153+
- build-macos-electron-1.8.6
154+
- build-macos-electron-1.7.11

appveyor.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@ environment:
66
- nodejs_version: 8
77
platform: x86
88
msvs_toolset: 14
9+
- nodejs_version: 10
10+
platform: x64
11+
msvs_toolset: 14
12+
- nodejs_version: 10
13+
platform: x86
14+
msvs_toolset: 14
915

1016
os: Visual Studio 2015
1117

0 commit comments

Comments
 (0)