chore(npm): move retry options to INSTALL_OPTS (#1564)

See: https://github.com/resin-io/etcher/pull/1550/files#r125015773
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
This commit is contained in:
Juan Cruz Viotti 2017-07-03 11:48:07 -04:00 committed by GitHub
parent 53d8118b8f
commit c2563c2f87

View File

@ -82,7 +82,7 @@ export npm_config_build_from_source=true
ELECTRON_ARCHITECTURE=$(./scripts/build/architecture-convert.sh -r "$ARGV_ARCHITECTURE" -t node)
export npm_config_arch=$ELECTRON_ARCHITECTURE
INSTALL_OPTS=""
INSTALL_OPTS="--fetch-retries 10 --fetch-retry-maxtimeout 180000"
if [ "$ARGV_PRODUCTION" == "true" ]; then
INSTALL_OPTS="$INSTALL_OPTS --production"
@ -101,7 +101,7 @@ function run_install() {
# since compiled add-ons will not work otherwise.
npm rebuild --silent
npm install --silent $INSTALL_OPTS --fetch-retries 10 --fetch-retry-maxtimeout 180000
npm install --silent $INSTALL_OPTS
if [ "$ARGV_PRODUCTION" == "true" ]; then