Skip to content

Commit

Permalink
fix: use nativeDirname instead of dirname
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonHK committed May 12, 2020
1 parent 3d6b4ce commit 9efe47d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/util/get-parsed-command-line/get-parsed-command-line.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {dirname, ensureAbsolute} from "../path/path-util";
import {ensureAbsolute, nativeDirname} from "../path/path-util";
import {D_TS_EXTENSION, DEFAULT_TSCONFIG_FILE_NAME} from "../../constant/constant";
import {ParsedCommandLineResult} from "./parsed-command-line-result";
import {
Expand Down Expand Up @@ -123,7 +123,7 @@ export function getParsedCommandLine(options: GetParsedCommandLineOptions): Pars
}

const tsconfigJson = typescript.parseConfigFileTextToJson(tsconfigPath, tsconfigContent).config;
const basePath = dirname(tsconfigPath);
const basePath = nativeDirname(tsconfigPath);

originalCompilerOptions = typescript.parseJsonConfigFileContent(tsconfigJson, fileSystem, basePath, {}, tsconfigPath).options;
parsedCommandLine = typescript.parseJsonConfigFileContent(tsconfigJson, fileSystem, basePath, forcedCompilerOptions, tsconfigPath);
Expand Down

0 comments on commit 9efe47d

Please sign in to comment.