Skip to content
This repository has been archived by the owner on Feb 18, 2019. It is now read-only.

Commit

Permalink
fix reference path separator on windows.
Browse files Browse the repository at this point in the history
  • Loading branch information
rei000 committed May 26, 2015
1 parent 7813895 commit b614014
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions lib/manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -595,10 +595,7 @@ export class Manager {
} else {
mkdirp.sync(_path.dirname(bundlePath));
}
var referencePath = _path.relative(_path.dirname(bundlePath), pathFromCwd);
if (_path.posix) {
referencePath = _path.posix.relative(_path.posix.dirname(bundlePath), pathFromCwd);
}
var referencePath = _path.relative(_path.dirname(bundlePath), pathFromCwd).replace(/\\/g, '/');
var referenceComment = `/// <reference path="${referencePath}" />` + "\n";
if (bundleContent.indexOf(referenceComment) === -1) {
fs.appendFileSync(bundlePath, referenceComment, {encoding: "utf8"});
Expand Down

0 comments on commit b614014

Please sign in to comment.