From b7633b9b8948baa620650629a6971043101fa19a Mon Sep 17 00:00:00 2001 From: Andrew Cherniavskii Date: Thu, 4 Jul 2019 19:00:21 +0200 Subject: [PATCH] copy .npmrc in case if packages are hosted in private registry --- src/makePatch.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/makePatch.ts b/src/makePatch.ts index 7f1d5502..63f1bb11 100644 --- a/src/makePatch.ts +++ b/src/makePatch.ts @@ -102,6 +102,12 @@ export function makePatch({ "package.json", )).version as string + // copy .npmrc in case if packages are hosted in private registry + const npmrcPath = join(appPath, ".npmrc") + if (existsSync(npmrcPath)) { + copySync(npmrcPath, join(tmpRepo.name, ".npmrc")) + } + if (packageManager === "yarn") { console.info( chalk.grey("•"),