mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-07-19 04:55:30 -04:00
minify images in parallel!
This commit is contained in:
@@ -23,10 +23,10 @@
|
||||
"serve:hugo": "hugo server --buildDrafts --buildFuture --port 1313 --bind 0.0.0.0 --verbose",
|
||||
"serve:docker": "docker build -t jarv.is:develop -f Dockerfile . && docker run -v $(pwd):/src -p 1313:1313 jarv.is:develop",
|
||||
"serve:netlify": "netlify dev --command 'yarn serve:hugo'",
|
||||
"optimize": "yarn optimize:html && yarn optimize:css && yarn optimize:img",
|
||||
"optimize": "get-folder-size --folder=public; yarn optimize:html && yarn optimize:css && yarn optimize:img; get-folder-size --folder=public",
|
||||
"optimize:html": "html-minifier --html5 --collapse-whitespace --preserve-line-breaks --minify-css --file-ext html --input-dir public --output-dir public **/*.html",
|
||||
"optimize:css": "cleancss -O0 --format 'keep-breaks' -o public/style.css public/style.css",
|
||||
"optimize:img": "find public/ -type d -exec imagemin {}/* --plugin=jpegoptim --plugin=pngquant --plugin=optipng --plugin=svgo --plugin=gifsicle --out-dir={} \\;",
|
||||
"optimize:img": "find public -type d | xargs -n1 -P8 -I{} imagemin {}/* --plugin=jpegoptim --plugin=pngquant --plugin=optipng --plugin=svgo --plugin=gifsicle --out-dir={}",
|
||||
"lint": "yarn lint:markdown; yarn lint:sass",
|
||||
"lint:markdown": "markdownlint content/notes/**/*.md",
|
||||
"lint:sass": "stylelint assets/sass/**/* --syntax scss",
|
||||
@@ -36,6 +36,7 @@
|
||||
"devDependencies": {
|
||||
"clean-css-cli": "~4.3.0",
|
||||
"cross-env": "^6.0.3",
|
||||
"get-folder-size": "^2.0.1",
|
||||
"html-minifier": "~4.0.0",
|
||||
"hugo-bin": "0.48.1",
|
||||
"imagemin-cli": "^5.0.0",
|
||||
@@ -47,6 +48,7 @@
|
||||
"markdownlint-cli": "~0.19.0",
|
||||
"netlify-cli": "^2.25.0",
|
||||
"rimraf": "^3.0.0",
|
||||
"shx": "^0.3.2",
|
||||
"stylelint": "~12.0.0",
|
||||
"stylelint-config-recommended-scss": "~4.1.0",
|
||||
"stylelint-scss": "~3.13.0"
|
||||
|
Reference in New Issue
Block a user