WIP - add extractor, generate snippet_data
This commit is contained in:
49
node_modules/pngquant-bin/readme.md
generated
vendored
Normal file
49
node_modules/pngquant-bin/readme.md
generated
vendored
Normal file
@ -0,0 +1,49 @@
|
||||
# pngquant-bin [](https://travis-ci.org/imagemin/pngquant-bin)
|
||||
|
||||
> [`pngquant`](https://github.com/pornel/pngquant) is a PNG compressor that significantly reduces file sizes by converting images to a more efficient 8-bit PNG format
|
||||
|
||||
You probably want [`imagemin-pngquant`](https://github.com/imagemin/imagemin-pngquant) instead.
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install pngquant-bin
|
||||
```
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
const execFile = require('child_process').execFile;
|
||||
const pngquant = require('pngquant-bin');
|
||||
|
||||
execFile(pngquant, ['-o', 'output.png', 'input.png'], err => {
|
||||
console.log('Image minified!');
|
||||
});
|
||||
```
|
||||
|
||||
|
||||
## CLI
|
||||
|
||||
```
|
||||
$ npm install --global pngquant-bin
|
||||
```
|
||||
|
||||
```
|
||||
$ pngquant --help
|
||||
```
|
||||
|
||||
|
||||
## Updating pre-compiled binaries
|
||||
|
||||
The Linux binaries are statically linked so they should work on all Linux distributions. To recompile them:
|
||||
|
||||
1. `sudo apt-get install libpng-dev`
|
||||
2. `./configure CFLAGS=-static && make && cp pngquant pngquant-64`
|
||||
3. Repeat the above commands, but in a 32-bin docker container started with: docker run -ti -v `pwd`:/source i386/debian:9.3 bash
|
||||
|
||||
|
||||
## License
|
||||
|
||||
MIT © [Imagemin](https://github.com/imagemin)
|
||||
Reference in New Issue
Block a user