Page 1 of 1

%%25 in filename

Posted: 2012-02-22T09:52:21-07:00
by aaronmueller
Hi!

I've noticed a problem on renaming for output files. Try this:

1. Name a File test.jpg
2. $ convert test.jpg "%%25.jpg"

The filename is "%25.jpg" after the convert. This happens not only on
the convert binary, the RMagick2 rubygem has the same behaviour.

I use Arch Linux (kernel 3.2), Imagemagick 6.7.5.3-1 and rmagick 2.13.1
from the repo.

Aaron

Re: %%25 in filename

Posted: 2012-02-23T19:33:28-07:00
by anthony
% is used in output filenames for adding 'frame numbers' to images.

for example page_%d.jpg

To escape a percent (and produce one percent) two percents are used. EG: %% produces one %

That is the reason!!!

Their is no switch or option at this time to make all filenames 'literal'.
Though that is a possibility as a future addition.

Re: %%25 in filename

Posted: 2012-02-27T03:03:58-07:00
by aaronmueller
ah that makes sense. Thanks!