关键词:
#First install the webp converter by this
sudo apt-get install webp
#go inside the directory where all images are there
#make sure all images are in RGB color mode, otherwise you will get error for CMYK images.
#Convert all images to RGB by this command (you should install ImageMagik to do that)
for f in *.jpg; do convert -colorspace RGB "$f" "$f"; done
#finally convert all images to Webp format
for f in *.jpg; do cwebp -q 90 "$f" -o "$f".webp; done
#Now you have filename.jpg.webp beside filename.jpg for all your images.
#You can set the nginx or other webservers to conditionally show webp instead of jpg if browser support
#Read this page to setup it in nginx config : https://github.com/uhop/grunt-tight-sprite/wiki/Recipe:-serve-WebP-with-nginx-conditionally
textbash档案(代码片段)
查看详情
textbash档案(代码片段)
查看详情
textbash快捷方式(代码片段)
查看详情
textbash脚本模板(代码片段)
查看详情
textbash脚本输入密码(代码片段)
查看详情
textbash:convertirungrupodearchivosjpgawebp(代码片段)
查看详情
textbash命令行#memo(代码片段)
查看详情
textbash_grep_pattern(代码片段)
查看详情
textbash_use_shadowsocks(代码片段)
查看详情
textbash的演示单元测试,只是个人使用(代码片段)
查看详情
textbash_sed_remove_colors(代码片段)
查看详情
textbash:为ansi文本颜色转义序列设置变量(代码片段)
查看详情
textbash/shellcli-input=flags模板(代码片段)
查看详情
textbash脚本显示k8s的pvc使用情况(代码片段)
查看详情
textbash:使用imagemagick(递归)从pdf中提取高分辨率图像(代码片段)
查看详情