Skip to content

Commit f089273

Browse files
committed
docs: fix example CLI
add example about comma separated arguments
1 parent 6d49895 commit f089273

File tree

1 file changed

+13
-10
lines changed

1 file changed

+13
-10
lines changed

docs/CLI.md

+13-10
Original file line numberDiff line numberDiff line change
@@ -28,28 +28,31 @@ To see the available options for the CLI: `purgecss --help`
2828
Usage: purgecss --css <css> --content <content> [options]
2929
3030
Options:
31-
-con, --content glob of content files
32-
-css, --css glob of css files
33-
-c, --config path to the configuration file
34-
-o, --output file path directory to write purged css files to
35-
-w, --whitelist list of classes that should not be removed
36-
-h, --help output usage information
31+
-con, --content <files> glob of content files (comma separated)
32+
-css, --css <files> glob of css files (comma separated)
33+
-c, --config <path> path to the configuration file
34+
-o, --output <path> file path directory to write purged css files to
35+
-font, --font-face option to remove unused font-faces
36+
-keyframes, --keyframes option to remove unused keyframes
37+
-rejected, --rejected option to output rejected selectors
38+
-w, --whitelist <list> list of classes that should not be removed (comma separated)
39+
-h, --help display help for command
3740
```
3841

3942
The options available through the CLI are similar to the ones available with a configuration file. You can also use the CLI with a configuration file.
4043

4144
### --css
4245

4346
```text
44-
purgecss --css css/app.css css/palette.css --content src/index.html
47+
purgecss --css css/app.css,css/palette.css --content src/index.html
4548
```
4649

4750
### --content
4851

49-
You can specify content that should be analyzed by PurgeCSS with an array of filenames or [globs](https://github.com/isaacs/node-glob/blob/master/README.md#glob-primer). These files can be HTML, Pug, Blade, etc.
52+
You can specify content that should be analyzed by PurgeCSS with an array of filenames or [globs](https://github.com/isaacs/node-glob/blob/master/README.md#glob-primer). These files can be HTML, Pug, Blade, etc. The files should be comma separated.
5053

5154
```text
52-
purgecss --css css/app.css --content src/index.html src/**/*.js
55+
purgecss --css css/app.css --content src/index.html,src/**/*.js
5356
```
5457

5558
### --config
@@ -65,7 +68,7 @@ purgecss --config ./purgecss.config.js
6568
By default, the CLI outputs the result in the console. If you wish to return the CSS as files, specify the directory to write the purified CSS files to.
6669

6770
```text
68-
purgecss --css css/app.css --content src/index.html src/**/*.js --output build/css/
71+
purgecss --css css/app.css --content src/index.html,src/**/*.js --output build/css/
6972
```
7073

7174
### --whitelist

0 commit comments

Comments
 (0)