Skip to content

Commit 6205c51

Browse files
committed
Adds the --version description in the help section. Fixes #7
1 parent 2ec8019 commit 6205c51

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ Install the module with: `npm install uglifyjs-folder -g`
2020
-y --harmony Uses uglify-js-harmony as a minifier
2121
-p --pattern Specifies a comma separated glob patterns for the file selections. Default: **/*.js
2222
--pseparator Specifies the separator for the pattern input. Default: ,
23+
--version Prints the current version from package.json
2324
-h --help Print this list and exit.
2425
## Examples
2526
$ uglifyjs-folder test-folder

cli.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ var cli = meow({
1717
' -y --harmony Uses uglify-js-harmony as a minifier',
1818
' -p --pattern Specifies a comma separated glob patterns for the file selections. Default: **/*.js',
1919
' --pseparator Specifies the separator for the pattern input. Default: ,',
20+
' --version Prints the current version from package.json',
2021
' -h --help Print this list and exit.'
2122
].join('\n')
2223
});
2324

24-
2525
var result = uglifyFolder(cli.input[0], {
2626
comments: cli.flags.comments || cli.flags.c || false,
2727
output: cli.flags.output || cli.flags.o,
@@ -31,7 +31,7 @@ var result = uglifyFolder(cli.input[0], {
3131
patterns: (cli.flags.pattern || cli.flags.p || "**/*.js").split(cli.flags.pseparator || ',')
3232
});
3333

34-
if(result) {
34+
if (result) {
3535
console.log(result);
3636
}
3737

0 commit comments

Comments
 (0)