Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Do not rebase on absolute file references
  • Loading branch information
Frank Schmid committed Nov 18, 2017
commit 697be1e869b77b3982c9a8708456a532e2fbbc13
2 changes: 1 addition & 1 deletion lib/packExternalModules.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function addModulesToPackageJson(externalModules, packageJson, pathToPackageRoot
}
let moduleVersion = _.join(_.tail(splitModule), '@');
// We have to rebase file references to the target package.json
if (_.startsWith(moduleVersion, 'file:')) {
if (/^file:[^/]{2}/.test(moduleVersion)) {
const filePath = _.replace(moduleVersion, /^file:/, '');
moduleVersion = _.replace(`file:${pathToPackageRoot}/${filePath}`, /\\/g, '/');
}
Expand Down