使用exiv2,可以在终端输出图像信息。但是,它会输出几行信息:
exiv2 -ps ~/filelocation/filename.jpg
输出如下内容:
File name : ~/filelocation/filename.jpg
File size : 12345 Bytes
MIME type : image/jpeg
Image size : 800 x 600
~/filelocation/filename.jpg: No Exif data found in the file
如何命令终端仅输出图像大小数据?
我真正想要的是:
exiv2 -ps ~/filelocation/filename.jpg [some command here]
输出:
800 x 600