Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
this._parser.trapErrors(() => {
if (error) {
throw error;
} else {
const commonRootPackage: Package = Package.createFromNpm(npmPackage);
const commonPackageLookup: PackageLookup = new PackageLookup();
commonPackageLookup.loadTree(commonRootPackage);
const rushLinkJson: IRushLinkJson = { localLinks: {} };
for (const rushProject of this._rushConfiguration.projects) {
console.log(os.EOL + 'LINKING: ' + rushProject.packageName);
linkProject(rushProject, commonRootPackage, commonPackageLookup, this._rushConfiguration, rushLinkJson);
}
console.log(`Writing "${this._rushConfiguration.rushLinkJsonFilename}"`);
JsonFile.saveJsonFile(rushLinkJson, this._rushConfiguration.rushLinkJsonFilename);
stopwatch.stop();
console.log(os.EOL + colors.green(`Rush link finished successfully. (${stopwatch.toString()})`));