Skip to content

Commit b84234f

Browse files
committed
chore(BinaryExtractionTask): add note to future me about -W vs -w and -out
1 parent 2d9caf4 commit b84234f

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/BinaryExtractionTask.ts

+9-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,15 @@ export class BinaryExtractionTask extends ExifToolTask<Maybe<string>> {
3838
...Utf8FilenameCharsetArgs,
3939
"-b", // -binary
4040
"-" + tagname,
41-
// capital W allows destination files to not have a pattern:
41+
// Capital W allows destination files to not have a pattern. See
42+
// https://exiftool.org/exiftool_pod.html#W-FMT--tagOut
43+
//
44+
// Prior code used -w with %0f "to avoid shell expansion", but as this
45+
// command gets sent directly to exiftool thanks to stay_open mode, we
46+
// don't need to worry about shell expansion.
47+
//
48+
// I also tried `-out` instead of `-W`, and that didn't work at least on
49+
// ExifTool 13.17.
4250
forceWrite ? "-W!" : "-W",
4351
path.resolve(imgDest),
4452
path.resolve(imgSrc),

0 commit comments

Comments
 (0)