A tool to modify the format of an image from the command line
npm install @xxhls/image-transformer -g
img-t --name='.*.tiff' --target='png' --path='./images' --recursion='true'
-
--name
: the name of the file, which can be a regular expression -
--target
: the converted target format -
--path
: the path of the file, the default is the current directory -
--recursion
: whether to recursion or not, the default is false
img-t --name='.*.png' --target='jpeg'
img-t --name='.*.png' --target='jpeg' --path='./images-test'
img-t --name='.*.tiff' --target='png' --path='E:\Projects\image-transformer\images-test'
img-t --name='.*.jpeg' --target='png' --path='E:\Projects\image-transformer\images-test' --recursion='true'
img-t --name='.*.(png|tiff)' --target='bmp' --path='E:\Projects\image-transformer\images-test' --recursion='true'
JPEG
JPG
PNG
BMP
TIFF
GIF
- v1.1.0: finish the most function
- v1.0.0: support the basic use