diff --git a/src/compiler/commandLineParser.ts b/src/compiler/commandLineParser.ts index f648bddefe9..395fe633a03 100644 --- a/src/compiler/commandLineParser.ts +++ b/src/compiler/commandLineParser.ts @@ -443,7 +443,6 @@ namespace ts { { name: "sourceRoot", type: "string", - isFilePath: true, paramType: Diagnostics.LOCATION, category: Diagnostics.Source_Map_Options, description: Diagnostics.Specify_the_location_where_debugger_should_locate_TypeScript_files_instead_of_source_locations, @@ -451,7 +450,6 @@ namespace ts { { name: "mapRoot", type: "string", - isFilePath: true, paramType: Diagnostics.LOCATION, category: Diagnostics.Source_Map_Options, description: Diagnostics.Specify_the_location_where_debugger_should_locate_map_files_instead_of_generated_locations, diff --git a/tests/baselines/reference/commonSourceDirectory.js b/tests/baselines/reference/commonSourceDirectory.js index ca705a5b34e..44991d1b84e 100644 --- a/tests/baselines/reference/commonSourceDirectory.js +++ b/tests/baselines/reference/commonSourceDirectory.js @@ -24,7 +24,7 @@ exports.__esModule = true; var foo_1 = require("foo"); var bar_1 = require("bar"); foo_1.x + bar_1.y; -//# sourceMappingURL=/app/myMapRoot/index.js.map +//# sourceMappingURL=../myMapRoot/index.js.map //// [/app/bin/index.d.ts] /// diff --git a/tests/baselines/reference/commonSourceDirectory.js.map b/tests/baselines/reference/commonSourceDirectory.js.map index fd88719859b..737c1dc3df1 100644 --- a/tests/baselines/reference/commonSourceDirectory.js.map +++ b/tests/baselines/reference/commonSourceDirectory.js.map @@ -1,2 +1,2 @@ //// [/app/bin/index.js.map] -{"version":3,"file":"index.js","sourceRoot":"/app/mySourceRoot/","sources":["index.ts"],"names":[],"mappings":";;AAAA,yCAAyC;AACzC,2BAAwB;AACxB,2BAAwB;AACxB,OAAC,GAAG,OAAC,CAAC"} \ No newline at end of file +{"version":3,"file":"index.js","sourceRoot":"mySourceRoot/","sources":["index.ts"],"names":[],"mappings":";;AAAA,yCAAyC;AACzC,2BAAwB;AACxB,2BAAwB;AACxB,OAAC,GAAG,OAAC,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/commonSourceDirectory.sourcemap.txt b/tests/baselines/reference/commonSourceDirectory.sourcemap.txt index c880d2d0059..567e435ce55 100644 --- a/tests/baselines/reference/commonSourceDirectory.sourcemap.txt +++ b/tests/baselines/reference/commonSourceDirectory.sourcemap.txt @@ -1,7 +1,7 @@ =================================================================== JsFile: index.js -mapUrl: /app/myMapRoot/index.js.map -sourceRoot: /app/mySourceRoot/ +mapUrl: ../myMapRoot/index.js.map +sourceRoot: mySourceRoot/ sources: index.ts =================================================================== ------------------------------------------------------------------- @@ -43,7 +43,7 @@ sourceFile:index.ts 3 > ^^^ 4 > ^^^^^^^ 5 > ^ -6 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +6 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > > 2 >x @@ -56,4 +56,4 @@ sourceFile:index.ts 4 >Emitted(6, 18) Source(4, 6) + SourceIndex(0) 5 >Emitted(6, 19) Source(4, 7) + SourceIndex(0) --- ->>>//# sourceMappingURL=/app/myMapRoot/index.js.map \ No newline at end of file +>>>//# sourceMappingURL=../myMapRoot/index.js.map \ No newline at end of file diff --git a/tests/baselines/reference/commonSourceDirectory_dts.js b/tests/baselines/reference/commonSourceDirectory_dts.js index 249edeceddd..1009ff9475b 100644 --- a/tests/baselines/reference/commonSourceDirectory_dts.js +++ b/tests/baselines/reference/commonSourceDirectory_dts.js @@ -15,7 +15,7 @@ export const x = y; exports.__esModule = true; /// exports.x = y; -//# sourceMappingURL=/app/myMapRoot/index.js.map +//# sourceMappingURL=../src/myMapRoot/index.js.map //// [/app/bin/index.d.ts] /// diff --git a/tests/baselines/reference/commonSourceDirectory_dts.js.map b/tests/baselines/reference/commonSourceDirectory_dts.js.map index 552da577884..2950d165917 100644 --- a/tests/baselines/reference/commonSourceDirectory_dts.js.map +++ b/tests/baselines/reference/commonSourceDirectory_dts.js.map @@ -1,2 +1,2 @@ //// [/app/bin/index.js.map] -{"version":3,"file":"index.js","sourceRoot":"/app/mySourceRoot/","sources":["index.ts"],"names":[],"mappings":";;AAAA,wCAAwC;AAC3B,QAAA,CAAC,GAAG,CAAC,CAAC"} \ No newline at end of file +{"version":3,"file":"index.js","sourceRoot":"mySourceRoot/","sources":["index.ts"],"names":[],"mappings":";;AAAA,wCAAwC;AAC3B,QAAA,CAAC,GAAG,CAAC,CAAC"} \ No newline at end of file diff --git a/tests/baselines/reference/commonSourceDirectory_dts.sourcemap.txt b/tests/baselines/reference/commonSourceDirectory_dts.sourcemap.txt index 925a3d30ed4..fb2ef3596c6 100644 --- a/tests/baselines/reference/commonSourceDirectory_dts.sourcemap.txt +++ b/tests/baselines/reference/commonSourceDirectory_dts.sourcemap.txt @@ -1,7 +1,7 @@ =================================================================== JsFile: index.js -mapUrl: /app/myMapRoot/index.js.map -sourceRoot: /app/mySourceRoot/ +mapUrl: ../src/myMapRoot/index.js.map +sourceRoot: mySourceRoot/ sources: index.ts =================================================================== ------------------------------------------------------------------- @@ -25,7 +25,7 @@ sourceFile:index.ts 4 > ^^^ 5 > ^ 6 > ^ -7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> +7 > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-> 1 > >export const 2 > @@ -40,4 +40,4 @@ sourceFile:index.ts 5 >Emitted(4, 14) Source(2, 19) + SourceIndex(0) 6 >Emitted(4, 15) Source(2, 20) + SourceIndex(0) --- ->>>//# sourceMappingURL=/app/myMapRoot/index.js.map \ No newline at end of file +>>>//# sourceMappingURL=../src/myMapRoot/index.js.map \ No newline at end of file diff --git a/tests/baselines/reference/tsConfig/Default initialized TSConfig/tsconfig.json b/tests/baselines/reference/tsConfig/Default initialized TSConfig/tsconfig.json index 0b72c3fd8a7..261cdca7011 100644 --- a/tests/baselines/reference/tsConfig/Default initialized TSConfig/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Default initialized TSConfig/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with advanced options/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with advanced options/tsconfig.json index 4d5c6053bcc..d3a9f8e9f47 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with advanced options/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with advanced options/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with boolean value compiler options/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with boolean value compiler options/tsconfig.json index f84c7f3abf3..8484e61bcfa 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with boolean value compiler options/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with boolean value compiler options/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with enum value compiler options/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with enum value compiler options/tsconfig.json index b65582c7841..35aa1cf7eab 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with enum value compiler options/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with enum value compiler options/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with files options/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with files options/tsconfig.json index 86d25e2362a..fbc441b823c 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with files options/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with files options/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option value/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option value/tsconfig.json index b623b1198c2..f758c1f6c20 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option value/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option value/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option/tsconfig.json index 0b72c3fd8a7..261cdca7011 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with incorrect compiler option/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options with enum value/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options with enum value/tsconfig.json index ea9df560138..cdb52963ccb 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options with enum value/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options with enum value/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ diff --git a/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options/tsconfig.json b/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options/tsconfig.json index bab4947a8e5..fd6419e1e35 100644 --- a/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options/tsconfig.json +++ b/tests/baselines/reference/tsConfig/Initialized TSConfig with list compiler options/tsconfig.json @@ -47,8 +47,8 @@ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */