fix(yarn): read yarnrc contents properly

Properly fixes #2020
This commit is contained in:
Rhys Arkins 2018-05-26 18:22:32 +02:00
parent 941d06172d
commit a9f47ca0b0

View file

@ -35,7 +35,6 @@ async function extractDependencies(content, packageFile, config) {
: 'app';
const lockFiles = {
yarnrc: '.yarnrc',
yarnLock: 'yarn.lock',
packageLock: 'package-lock.json',
shrinkwrapJson: 'npm-shrinkwrap.json',
@ -71,6 +70,10 @@ async function extractDependencies(content, packageFile, config) {
npmrc = undefined;
}
}
const yarnrc =
(await platform.getFile(
upath.join(path.dirname(packageFile), '.yarnrc')
)) || undefined;
let lernaDir;
let lernaPackages;
@ -131,6 +134,7 @@ async function extractDependencies(content, packageFile, config) {
packageJsonVersion,
packageJsonType,
npmrc,
yarnrc,
...lockFiles,
lernaDir,
lernaClient,