Skip to content

Commit d1f756f

Browse files
author
James Halliday
committed
outpipe example in the readme
1 parent 81210fc commit d1f756f

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

readme.markdown

+11
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,17 @@ $ cat bundle/common.js bundle/y.js | node
8484
333
8585
```
8686

87+
## command-line outpipe example
88+
89+
We can pipe each output file through some other processes. Here we'll do
90+
minification with uglify compression with gzip:
91+
92+
``` sh
93+
browserify files/*.js \
94+
-p [ ../ -o 'uglifyjs -cm | gzip > bundle/`basename $FILE`.gz' ] \
95+
| uglifyjs -cm | gzip > bundle/common.js.gz
96+
```
97+
8798
## api plugin example
8899

89100
If you prefer you can use the factor-bundle plugin api directly in code:

0 commit comments

Comments
 (0)