Add a SVGO Docker image

This commit is contained in:
Oleg Nenashev 2019-07-15 19:02:08 +02:00
parent 3af76b75d3
commit 32993385da
3 changed files with 15 additions and 0 deletions

3
.dockerignore Normal file
View file

@ -0,0 +1,3 @@
Dockerfile
README.md
icons/*

View file

@ -83,6 +83,10 @@ All icons in Simple Icons have been optimized with the [SVGO tool](https://githu
* Set the precision to about 3, depending on if there is a loss of quality.
* Leave the remaining settings untouched (or reset them with the button at the bottom of the settings).
* Click the download button.
* The [SVGO Command Line Tool](https://github.com/svg/svgo) in Docker
* If none of the options above work for you, it is possible to build a Docker image for compressing the images
* Build: `docker build -t simple-icons/svgo-optimizer .`
* Run: `docker run --rm -v ${full local path}:/image.svg simple-icons/svgo-optimizer`
### 4. Annotate The Icon

8
Dockerfile Normal file
View file

@ -0,0 +1,8 @@
FROM node:6
WORKDIR /work
COPY package*.json /work/
RUN npm install
COPY * /work/
ENTRYPOINT [ "npm", "run", "svgo", "--", "/image.svg" ]