9
9
stepback : false
10
10
11
11
variables :
12
- # function "fetch npm tarball" is conditional on {fetch_npm_tarball}
13
- # -> all except windows
14
-
15
- # function "upgrade npm windows" is conditional based on {upgrade_npm_version}
16
- # as set in the buildvariant declaration
17
- # -> only windows
18
-
19
12
# function "save release variants" is conditional on the following
20
13
# -> all except ubuntu
21
14
- &save_release_variants
@@ -57,42 +50,19 @@ functions:
57
50
script : |
58
51
mkdir -p .deps
59
52
set -ev
60
- if [ -z "${fetch_npm_tarball|}" ]; then
61
- echo "fetch_npm_tarball: fetch_npm_tarball is unset; skipping"
62
- exit 0
63
- fi
64
53
curl -fs \
65
54
-o ".deps/${fetch_npm_tarball}" \
66
55
--url "http://mongodb-dx-public.s3.amazonaws.com/evergreen-deps/${fetch_npm_tarball}"
67
56
cd .deps
68
57
tar xzf ${fetch_npm_tarball} --strip-components=1
69
58
70
- # THIS COMMAND WORKS ON WINDOWS ONLY, SHOULD BE CONSIDERED OBSOLETE
71
- # To use "npm" installed by this, each shell.exec script must add:
72
- # export PATH="`npm -g bin`:$PATH"
73
- " upgrade npm windows" : &upgrade_npm_windows
74
- command : shell.exec
75
- params :
76
- working_dir : src
77
- script : |
78
- if [ -z "${upgrade_npm_version|}" ]; then
79
- echo "upgrade_npm: upgrade_npm_version is unset; skipping"
80
- exit 0
81
- fi
82
- set -ev
83
- test -n "${node_environment|}" && export "${node_environment|}"
84
- export PATH="$PATH:${node_path|}"
85
- ${npm|npm} install -g npm@${upgrade_npm_version|xx}
86
-
87
59
" npm install" :
88
60
command : shell.exec
89
61
params :
90
62
working_dir : src
91
63
script : |
92
64
set -ev
93
- test -n "${node_environment|}" && export "${node_environment|}"
94
- export PATH="$PATH:${node_path|}"
95
- export PATH="`npm -g bin`:$PATH"
65
+ export PATH="${node_path}:$PATH"
96
66
${node|node} --version
97
67
${npm|npm} --version
98
68
${npm|npm} config set loglevel error
@@ -106,9 +76,7 @@ functions:
106
76
working_dir : src
107
77
script : |
108
78
set -ev
109
- test -n "${node_environment|}" && export "${node_environment|}"
110
- export PATH="$PATH:${node_path|}"
111
- export PATH="`npm -g bin`:$PATH"
79
+ export PATH="${node_path}:$PATH"
112
80
export CI=1 EVERGREEN=1
113
81
test -n "${add_environment|}" && export ${add_environment|}
114
82
${npm|npm} run ci
@@ -160,7 +128,6 @@ tasks:
160
128
commands :
161
129
- func : " fetch source"
162
130
- func : " fetch npm tarball"
163
- - func : " upgrade npm windows"
164
131
- func : " npm install"
165
132
- func : " build"
166
133
- func : " save release"
@@ -195,9 +162,8 @@ buildvariants:
195
162
run_on :
196
163
- " windows-64-vs2013-test"
197
164
expansions :
198
- node_environment : " APPDATA=C:\\ Program Files (x86)\\ nodejs\\ node_modules"
199
- upgrade_npm_version : " 3"
200
- node_path : " /cygdrive/c/Program Files (x86)/nodejs"
165
+ fetch_npm_tarball : node-v4.2.2-npm-3.3.12-windows-x64.tgz
166
+ node_path : " $(pwd)/.deps"
201
167
installer_content_type : " application/octet-stream"
202
168
installer_filename : " MongoDBCompassSetup.exe"
203
169
num_cores : $(grep -c ^processor /proc/cpuinfo)
0 commit comments