mirror of
https://github.com/renovatebot/renovate.git
synced 2025-01-12 23:16:26 +00:00
feat(npm): Update Yarn install arguments (#7156)
Co-authored-by: Rhys Arkins <rhys@arkins.net> Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
This commit is contained in:
parent
2d344b1a69
commit
6fb36435f4
2 changed files with 11 additions and 4 deletions
|
@ -115,7 +115,7 @@ Array [
|
||||||
exports[`manager/npm/post-update/yarn generates lock files using yarn v2.1.0 1`] = `
|
exports[`manager/npm/post-update/yarn generates lock files using yarn v2.1.0 1`] = `
|
||||||
Array [
|
Array [
|
||||||
Object {
|
Object {
|
||||||
"cmd": "yarn install --ignore-engines --ignore-platform --network-timeout 100000",
|
"cmd": "yarn install",
|
||||||
"options": Object {
|
"options": Object {
|
||||||
"cwd": "some-dir",
|
"cwd": "some-dir",
|
||||||
"encoding": "utf-8",
|
"encoding": "utf-8",
|
||||||
|
@ -128,6 +128,7 @@ Array [
|
||||||
"NO_PROXY": "localhost",
|
"NO_PROXY": "localhost",
|
||||||
"PATH": "/tmp/path",
|
"PATH": "/tmp/path",
|
||||||
"YARN_ENABLE_SCRIPTS": "0",
|
"YARN_ENABLE_SCRIPTS": "0",
|
||||||
|
"YARN_HTTP_TIMEOUT": "100000",
|
||||||
},
|
},
|
||||||
"timeout": 900000,
|
"timeout": 900000,
|
||||||
},
|
},
|
||||||
|
@ -228,7 +229,7 @@ Array [
|
||||||
exports[`manager/npm/post-update/yarn performs lock file maintenance using yarn v2.1.0 1`] = `
|
exports[`manager/npm/post-update/yarn performs lock file maintenance using yarn v2.1.0 1`] = `
|
||||||
Array [
|
Array [
|
||||||
Object {
|
Object {
|
||||||
"cmd": "yarn install --ignore-engines --ignore-platform --network-timeout 100000",
|
"cmd": "yarn install",
|
||||||
"options": Object {
|
"options": Object {
|
||||||
"cwd": "some-dir",
|
"cwd": "some-dir",
|
||||||
"encoding": "utf-8",
|
"encoding": "utf-8",
|
||||||
|
@ -241,6 +242,7 @@ Array [
|
||||||
"NO_PROXY": "localhost",
|
"NO_PROXY": "localhost",
|
||||||
"PATH": "/tmp/path",
|
"PATH": "/tmp/path",
|
||||||
"YARN_ENABLE_SCRIPTS": "0",
|
"YARN_ENABLE_SCRIPTS": "0",
|
||||||
|
"YARN_HTTP_TIMEOUT": "100000",
|
||||||
},
|
},
|
||||||
"timeout": 900000,
|
"timeout": 900000,
|
||||||
},
|
},
|
||||||
|
|
|
@ -74,8 +74,13 @@ export async function generateLockFile(
|
||||||
preCommands.push(optimizeCommand);
|
preCommands.push(optimizeCommand);
|
||||||
}
|
}
|
||||||
const commands = [];
|
const commands = [];
|
||||||
let cmdOptions =
|
let cmdOptions = '';
|
||||||
'--ignore-engines --ignore-platform --network-timeout 100000';
|
if (isYarn1) {
|
||||||
|
cmdOptions +=
|
||||||
|
'--ignore-engines --ignore-platform --network-timeout 100000';
|
||||||
|
} else {
|
||||||
|
extraEnv.YARN_HTTP_TIMEOUT = '100000';
|
||||||
|
}
|
||||||
if (global.trustLevel !== 'high' || config.ignoreScripts) {
|
if (global.trustLevel !== 'high' || config.ignoreScripts) {
|
||||||
if (isYarn1) {
|
if (isYarn1) {
|
||||||
cmdOptions += ' --ignore-scripts';
|
cmdOptions += ' --ignore-scripts';
|
||||||
|
|
Loading…
Reference in a new issue