@@ -49,6 +49,9 @@ The available options are:
|
|||||||
[string]
|
[string]
|
||||||
--source-map-root The path to the original source to be included in the
|
--source-map-root The path to the original source to be included in the
|
||||||
source map. [string]
|
source map. [string]
|
||||||
|
--source-map-url The path to the source map to be added in //@
|
||||||
|
sourceMappingURL. Defaults to the value passed with
|
||||||
|
--source-map. [string]
|
||||||
--in-source-map Input source map, useful if you're compressing JS that was
|
--in-source-map Input source map, useful if you're compressing JS that was
|
||||||
generated from some other original code.
|
generated from some other original code.
|
||||||
-p, --prefix Skip prefix for original filenames that appear in source
|
-p, --prefix Skip prefix for original filenames that appear in source
|
||||||
@@ -85,8 +88,9 @@ The available options are:
|
|||||||
[string]
|
[string]
|
||||||
--export-all Only used when --wrap, this tells UglifyJS to add code to
|
--export-all Only used when --wrap, this tells UglifyJS to add code to
|
||||||
automatically export all globals. [boolean]
|
automatically export all globals. [boolean]
|
||||||
|
--lint Display some scope warnings [boolean]
|
||||||
-v, --verbose Verbose [boolean]
|
-v, --verbose Verbose [boolean]
|
||||||
-V, --version Print version number and exits. [boolean]
|
-V, --version Print version number and exit. [boolean]
|
||||||
|
|
||||||
Specify `--output` (`-o`) to declare the output file. Otherwise the output
|
Specify `--output` (`-o`) to declare the output file. Otherwise the output
|
||||||
goes to STDOUT.
|
goes to STDOUT.
|
||||||
|
|||||||
@@ -19,6 +19,7 @@ mangling you need to use `-c` and `-m`.\
|
|||||||
")
|
")
|
||||||
.describe("source-map", "Specify an output file where to generate source map.")
|
.describe("source-map", "Specify an output file where to generate source map.")
|
||||||
.describe("source-map-root", "The path to the original source to be included in the source map.")
|
.describe("source-map-root", "The path to the original source to be included in the source map.")
|
||||||
|
.describe("source-map-url", "The path to the source map to be added in //@ sourceMappingURL. Defaults to the value passed with --source-map.")
|
||||||
.describe("in-source-map", "Input source map, useful if you're compressing JS that was generated from some other original code.")
|
.describe("in-source-map", "Input source map, useful if you're compressing JS that was generated from some other original code.")
|
||||||
.describe("p", "Skip prefix for original filenames that appear in source maps. \
|
.describe("p", "Skip prefix for original filenames that appear in source maps. \
|
||||||
For example -p 3 will drop 3 directories from file names and ensure they are relative paths.")
|
For example -p 3 will drop 3 directories from file names and ensure they are relative paths.")
|
||||||
@@ -63,6 +64,7 @@ You need to pass an argument to this option to specify the name that your module
|
|||||||
|
|
||||||
.string("source-map")
|
.string("source-map")
|
||||||
.string("source-map-root")
|
.string("source-map-root")
|
||||||
|
.string("source-map-url")
|
||||||
.string("b")
|
.string("b")
|
||||||
.string("m")
|
.string("m")
|
||||||
.string("c")
|
.string("c")
|
||||||
@@ -277,7 +279,7 @@ output = output.get();
|
|||||||
|
|
||||||
if (SOURCE_MAP) {
|
if (SOURCE_MAP) {
|
||||||
fs.writeFileSync(ARGS.source_map, SOURCE_MAP, "utf8");
|
fs.writeFileSync(ARGS.source_map, SOURCE_MAP, "utf8");
|
||||||
output += "\n//@ sourceMappingURL=" + ARGS.source_map;
|
output += "\n//@ sourceMappingURL=" + (ARGS.source_map_url || ARGS.source_map);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (OUTPUT_FILE) {
|
if (OUTPUT_FILE) {
|
||||||
|
|||||||
Reference in New Issue
Block a user