Skip to content

Commit

Permalink
Merge pull request #629 from alexander-zierhut/patch-1
Browse files Browse the repository at this point in the history
Added some more context to the CLI exclude/include/match options
  • Loading branch information
tdewolff authored Oct 31, 2023
2 parents b245a57 + d79b173 commit e95914c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cmd/minify/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,8 @@ The patterns for `--match`, `--include`, and `--exclude` can be either a glob or

Match will filters all files by the given pattern, eg. `--match '*.css'` will only minify CSS files. The `--include` and `--exclude` options allow to add or remove certain files or directories and is interpreted in the order given. For example, `minify -rvo out/ --exclude 'src/*/**' --include 'src/foo/**' src/` will minify the directory `src/`, except for `src/*/...` where `*` is not `foo`.

You may define multiple patterns within one option, such as: `--exclude '**/folder1/**' '**/folder2/**' '**/folder3/**'` Doing this might result in unexpected behaviour when it is followed immediately by the input files, as this would be interpreted as another pattern, and not as inputs. `--exclude dir_to_exclude folder_input` Instead format accordingly: `--exclude dir_to_exclude -- folder_input`. This may be subject to change.

### Concatenate
When multiple inputs are given and the output is either standard output or a single file, it will concatenate the files together if you use the bundle option.

Expand Down

0 comments on commit e95914c

Please sign in to comment.