@pnpm/npm-resolver
Advanced tools
Comparing version 0.3.7 to 0.3.9
@@ -64,2 +64,3 @@ "use strict"; | ||
auth, | ||
dryRun: opts.dryRun === true, | ||
offline: ctx.offline, | ||
@@ -66,0 +67,0 @@ registry: opts.registry, |
@@ -25,2 +25,3 @@ import { PackageManifest } from '@pnpm/types'; | ||
registry: string; | ||
dryRun: boolean; | ||
}): Promise<PackageMeta>; |
@@ -55,11 +55,13 @@ "use strict"; | ||
metaCache.set(spec.name, meta); | ||
limit(() => saveMeta(pkgMirror, meta)); | ||
if (!opts.dryRun) { | ||
limit(() => saveMeta(pkgMirror, meta)); | ||
} | ||
return meta; | ||
} | ||
catch (err) { | ||
const meta = yield loadMeta(opts.storePath); | ||
const meta = yield loadMeta(pkgMirror); // TODO: add test for this usecase | ||
if (!meta) | ||
throw err; | ||
logger_1.default.error(err); | ||
logger_1.default.info(`Using cached meta from ${opts.storePath}`); | ||
logger_1.default.info(`Using cached meta from ${pkgMirror}`); | ||
return meta; | ||
@@ -66,0 +68,0 @@ } |
{ | ||
"name": "@pnpm/npm-resolver", | ||
"version": "0.3.7", | ||
"version": "0.3.9", | ||
"description": "Resolver for npm-hosted packages", | ||
@@ -68,2 +68,3 @@ "main": "lib/index.js", | ||
"package-preview": "^1.0.1", | ||
"path-exists": "^3.0.0", | ||
"pnpm-registry-mock": "^1.18.0", | ||
@@ -70,0 +71,0 @@ "rimraf": "^2.6.2", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
28921
351
15