[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: exif --remove not idempotent, and a Debian man page bug



On Wed, Sep 21, 2022 at 09:02:09AM +0200, Emanuel Berg wrote:
>     <incal> I'll mail Lutz Mueller <lutz@users.sourceforge.net> as well

According to the package metadata, the Debian maintainer of exif is:

Maintainer: Debian PhotoTools Maintainers <pkg-phototools-devel@lists.alioth.debian.org>

>     <incal> for f in **/*.jpg; do exif --remove -o $f $f; done | grep 'Wrote
>             file' | wc -l # 2277 (1st invocation)

I hope you're not using bash here.  If you are, the "$f" instances need
to be double-quoted, or else this is going to fail spectacularly on
filenames with whitespace or globbing characters.

Of course, ** doesn't work by default in bash; you have to enable it with
shopt -s globstar beforehand.  The fact that you didn't show this step,
however, doesn't prove you're in a non-bash shell.

>     <incal> for f in **/*.jpg; do exif --remove -o $f $f; done | grep 'Wrote
>             file' | wc -l # 2277 (2nd invocation)

I don't know what the intended behaviof of "exif --remove -o file file"
is.  I'm imagining that it's like "sed -i" which always opens and writes
a new instance of the file, even if no changes are made.

>     <incal> Debian should remove that from the man page then, i.e. exif(1)

Remove what?  Perhaps what you actually want is additional clarity
about how the --remove option (or the -o option) works.

In any case, if you want to file a Debian bug report, see
<https://www.debian.org/Bugs/>.


Reply to: