[READ-ONLY] Mirror of https://github.com/probablykasper/to. CLI audio, video and image file converter
aiff audio cli flac gif image jp2 jpg mov mp3 mp4 ogg png video webm webp
0

Configure Feed

Select the types of activity you want to include in your feed.

Added webp custom quality support (to webp:75)

+9 -9
+2 -2
README.md
··· 43 43 44 44 Image formats: 45 45 jpg 95 quality. Custom quality example: jpg:75 (0-100) 46 - jp2 95 quality. Custom quality example: jpg:75 (0-100) 46 + jp2 95 quality. Custom quality example: jp2:75 (0-100) 47 47 png 48 - webp 48 + webp 95 quality. Custom quality example: webp:75 (0-100) 49 49 ``` 50 50 51 51 # Dev Instructions
+7 -7
bin/to
··· 44 44 45 45 `green Image formats:` 46 46 `cyan jpg` 95 quality. Custom quality example: `yellow jpg:75` (0-100) 47 - `cyan jp2` 95 quality. Custom quality example: `yellow jpg:75` (0-100) 47 + `cyan jp2` 95 quality. Custom quality example: `yellow jp2:75` (0-100) 48 48 `cyan png` 49 - `cyan webp` 49 + `cyan webp` 95 quality. Custom quality example: `yellow webp:75` (0-100) 50 50 " 51 51 } 52 52 ··· 108 108 109 109 # format 110 110 case "$FORMAT" in 111 - mp4|mov|webm|wav|flac|aac|aiff|ogg|webp) 111 + mp4|mov|webm|wav|flac|aac|aiff|ogg) 112 112 ;; 113 113 mp3) 114 114 if [[ $AUDIO_BITRATE_CHANGED != true ]]; then ··· 129 129 png) 130 130 CMD=magick 131 131 ;; 132 - jpg|jp2) 132 + jpg|jp2|webp) 133 133 CMD=magick 134 134 if [[ $QUALITY_CHANGED != true ]]; then 135 135 OPTIONS+=("-quality" "95") 136 136 fi 137 137 ;; 138 - jpg:*|jp2:*) 138 + jpg:*|jp2:*|webp:*) 139 139 CMD=magick 140 - JPG_JP2_REGEX="^(jpg|jp2)(:|-|\/)?([0-9]{1,3})(%)?$" 141 - if [[ "$FORMAT" =~ $JPG_JP2_REGEX ]]; then 140 + REGEX="^(jpg|jp2|webp)(:|-|\/)?([0-9]{1,3})(%)?$" 141 + if [[ "$FORMAT" =~ $REGEX ]]; then 142 142 FORMAT="${BASH_REMATCH[1]}" 143 143 if [[ $QUALITY_CHANGED != true ]]; then 144 144 OPTIONS+=("-quality" "${BASH_REMATCH[3]}")