Page 1 of 1

Command line problem in $MS Windows (identify -format)

Posted: 2007-06-20T10:33:12-07:00
by sinasalek
Hi,
I had a problem with using imagemagick command line in windows.
So i searched a lot on the internet specially in magick-bug but i couldn't find any solution.
even Youssef solution didn't help (also you can read the problem details in this thread) :

http://studio.imagemagick.org/pipermail ... 01257.html

finally i accidentally came up with a solution, and here is the berief description of the problem :
try to use this command and you will see that it only prints "h" :

identify -format "%w %h" file.jpg

it's because windows recognize %w or %w% as a command line variables so will replace it with its value, and as long as it's not defined windows replace it with nothing!!

the solution is to using two percent sign like %%w. so below command will give correct result

identify -format "%%w %%h" file.jpg

hope it helps someone ;)

PS : i wish if imagemagick lead developers could use trac.edgewall.org as bug tracking system. it's a lot easier to assign bugs and search through previous bugs.

Re: Command line problem in $MS Windows (identify -format)

Posted: 2007-06-20T10:37:25-07:00
by magick
We have looked at Trac, Jira, and Bugzilla. We have not launched a solution just yet due to lack of time/interest.

Re: Command line problem in $MS Windows (identify -format)

Posted: 2007-06-20T10:53:19-07:00
by sinasalek
magick wrote:We have looked at Trac, Jira, and Bugzilla. We have not launched a solution just yet due to lack of time/interest.
Glad to hear that. ;)