Skip to content

Commit

Permalink
feat: ensure npm link error to be fully exposed
Browse files Browse the repository at this point in the history
  • Loading branch information
medikoo committed Nov 9, 2018
1 parent 12f754d commit a449389
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion lib/install-package.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,15 @@ const setupDependencies = async (packageName, { packagesPath, packagesMeta, hook

const linkPackage = async (packagePath, packageName) => {
log.info("link %s", packageName);
await runProgram("npm", ["link"], { cwd: packagePath, logger: log.levelRoot.get("npm:link") });
try {
await runProgram("npm", ["link"], {
cwd: packagePath,
logger: log.levelRoot.get("npm:link")
});
} catch (error) {
log.error("npm link errored: %o", error);
throw error;
}
};

module.exports = ee(async (packageName, { packagesPath, packagesMeta, hooks }) => {
Expand Down

0 comments on commit a449389

Please sign in to comment.