aboutsummaryrefslogtreecommitdiff
path: root/bin
AgeCommit message (Collapse)Author
2017-03-24fix regression: CLI options with hyphens like -b ascii-only (#1640)kzc
fixes #1637
2017-03-05stay safe with constants in IE8- (#1547)Alex Lam S.L
- `undefined` etc. can be redefined at top-level for IE8-, so disable related optimisations - fixed `--support-ie8` catch mangle bug
2017-03-05resolve issue with outdated version of async (#1549)Alex Lam S.L
fixes #746
2017-02-27improve error messages (#1506)Alex Lam S.L
- better inheritance of `Error` sub-classes - mark parse error against source in CLI closes #235 closes #348 closes #524 closes #1356 closes #1405
2017-02-25allow --in-source-map inline (#1490)Alex Lam S.L
- limited to one input file (or `stdin`) - only works with built-in parser fixes #520
2017-02-21clean up `max_line_len`alexlamsl
- never exceed specified limit - otherwise warning is shown - enabled only for final output closes #1496
2017-01-26fix mangling collision with keep_fnames (#1431)Alex Lam S.L
* fix mangling collision with keep_fnames fixes #1423 * pass mangle options to figure_out_scope() bring command-line in line with minify()
2017-01-19Have minify() and tests use figure_out_scope() as uglifyjs CLI doeskzc
Clarify docs, help and tests for --support-ie8 and screw_ie8=false
2016-11-29Add --mangle-props-debug and fix --mangle-props=unquoted collisionAshley (Scirra)
Patch by @AshleyScirra Based on: PR #1316 Renamed the CLI debug option to --mangle-props-debug Fixes: #1321 name collision in --mangle-props=unquoted
2016-10-23Don't filter shebangs when using the 'some' comment filterAnthony Van de Gejuchte
Also clarify documentation a bit more about using regexp as filter
2016-10-23Add an option for writing inline source mappengzhenqing
2016-10-06Add an option to wrap IIFEs in parenthesisRichard van Velzen
For #1307.
2016-09-06Make all comment options in cli available in js apiAnthony Van de Gejuchte
Also removing more code within "loop" while at it.
2016-08-14Add simple file globbing to bin/uglifyjs for Windowskzc
2016-06-30Enable --screw-ie8 by default.kzc
catch identifier is mangled correctly for ES5 standards-compliant JS engines by default. Unconditionally use the ie8 if/do-while workaround whether or not --screw-ie8 is enabled. To support non-standard ie8 javascript use: uglifyjs --support-ie8
2016-06-19Respect quote style in object literalsShrey Banga
The option added in fbbaa42ee55a7f753f7cab9b1a905ccf73cf26d5 wasn't being respected inside object literals, so quoted property names would still be stripped out with this option. This is mostly a corner-case, but useful when the output is passed to something like the Closure compiler, where quoted property names can be used to prevent mangling.
2016-04-19Add `passes` compress option. Fix duplicate compress warnings.kzc
2016-02-17Allow --no-* options to disable their respective parameterRichard van Velzen
Fixes #974 and #972
2016-02-10Allow cli options to be specified in separate definitionsRichard van Velzen
Fix for #963. This allows stuff like `--define a=1 --define b=1` besides only `--define a=1,b=1`
2015-11-11Rework has_directiveMihai Bazon
It's now available during tree walking, i.e. walker.has_directive("use asm"), rather than as part of the scope. It's thus no longer necessary to call `figure_out_scope` before codegen. Added special bits in the code generator to overcome the fact that it doesn't inherit from TreeWalker. Fix #861
2015-11-01Fixed RegExp literal in mozilla AST generation/output and added a ↵kzc
--dump-spidermonkey-ast flag
2015-10-13add `--pure-funcs` optionDamian Krzeminski
it has the same effect as specifying `pure_funcs` in `--compressor` option, however it's much easier to use instead of: --compressor 'pure_func=["Math.floor","debug","console.logTime"]' it's now possible: --compressor --pure-funcs Math.floor debug console.logTime fixes #684
2015-10-07get rid of SCOPE_IS_NEEDED as it was always truekzc
2015-10-07Fix handling of "use asm" when no command line flags are passed to uglifyjs. ↵kzc
SCOPE_IS_NEEDED is unconditionally true now. Refactored floating point literal parsing to be more in keeping with the AST class design.
2015-10-07Add proper support for "use asm"; blocks. Disable -c optimization within ↵kzc
"use asm"; sections and preserve floating point literals in their original form. Non-asm.js sections are optimized as before. Asm.js sections can still be mangled and minified of whitespace. No special command line flags are required.
2015-09-24No longer use `vm` to load code.Mihai Bazon
Improves performance 2x on node > 0.10. Ref #636
2015-06-09Change --mangle-regex to accept a full regexJoao Carlos
2015-06-09Show descriptive error when --mangle-regex is invalidJoao Carlos
2015-06-09Add --mangle-regex optionJoao Carlos
2015-05-04Remove deprecated calls to utils.print/utils.errorMihai Bazon
Close #542, #641, #647
2015-04-22If name_cache is specified, do rename cached propertiesMihai Bazon
(even if --mangle-props is not there)
2015-04-05More fixes for the breaking changes in yargsMihai Bazon
Close #670
2015-03-29Fix long optionsなつき
2015-03-29Add tool to extract property namesMihai Bazon
2015-03-22Export readDefaultReservedFileMihai Bazon
2015-03-18Add --reserve-domprops along with a default exclusion list in ↵Mihai Bazon
tools/domprops.json
2015-03-18Support multiple --reserved-file argsMihai Bazon
2015-03-17Export readNameCache / writeNameCacheMihai Bazon
2015-03-16rename --prop-cache to --name-cacheMihai Bazon
... and support storing there variable names as well, to help with multiple invocations when mangling toplevel.
2015-03-14Fix --reserved-fileMihai Bazon
2015-03-14Add property name manglerMihai Bazon
We only touch properties that are present in an object literal, or which are assigned to. Example: x = { foo: 1 }; x.bar = 2; x["baz"] = 3; x[cond ? "qwe" : "asd"] = 4; console.log(x.stuff); The names "foo", "bar", "baz", "qwe" and "asd" will be mangled, and the resulting mangled names will be used for the same properties throughout the code. The "stuff" will not be, since it's just referenced but never assigned to. This *will* break most of the code out there, but could work on carefully written code: do not use eval, do not define methods or properties by walking an array of names, etc. Also, a comprehensive list of exclusions needs to be passed, to avoid mangling properties that are standard in JavaScript, DOM, used in external libraries etc.
2015-02-11Parse regexes properlyAnthony Van de Gejuchte
2015-01-27Add option to preserve/enforce string quote styleMihai Bazon
`-q 0` (default) use single or double quotes such as to minimize the number of bytes (prefers double quotes when both will do); this is the previous behavior. `-q 1` -- always use single quotes `-q 2` -- always use double quotes `-q 3` or just `-q` -- always use the original quotes. Related codegen option: `quote_style`. Close #495 Close #460 Some `yargs` guru please tell me why `uglifyjs --help` doesn't display the help string for `-q` / `--quotes`, and why it doesn't output the expected argument types anymore, like good old `optimist` did.
2015-01-05Declare boolean type for --keep-fnamesMihai Bazon
2015-01-05Support keep_fnames in compressor, and --keep-fnames. #552Mihai Bazon
Passing `--keep-fnames` will enable it both for compressor/mangler, so that function names will not be dropped (when unused) nor mangled.
2015-01-04Fix backslashes in source-map paths on WindowsDerek Wickern
2015-01-01Use yargs instead of optimist.Kenneth Powers
2014-10-20Add option to allow return outside of functions.Mihai Bazon
Close #288
2014-01-09Added support for sourcesContent property of source mapArtemy Tregubenko
2014-01-07Fix #392Mihai Bazon