mirror of
https://github.com/storytold/photocraft.git
synced 2026-11-21 01:18:43 +00:00
File › Automate › Batch now covers Photoshop's dialog (AUTO-219-5):
- Source: a folder with Include All Subfolders (the output mirrors the
folder tree, so same-named files in different subfolders don't
collide), or the open documents (`"source": "open"`: the steps run on
every open document as history steps; with an output folder a copy of
each is saved there).
- File Naming: a template with Photoshop's fields as tokens: {name}
{NAME} {Name}, {serial} to {serial:4} from startSerial, {letter}
{LETTER}, {date:mmddyy|mmdd|yyyymmdd|yymmdd|yyddmm|ddmmyy}, {ext}
{EXT}, other text literal. Default {name}.{ext}, the old naming.
- Errors: stopOnError stops at the first failing file and reports the
skipped ones; errorLog writes the failures to a text file.
- The command runs as a job: the status bar shows "n of total: file"
and Cancel stops after the current file.
The options live in the new engine module `batch` and are shared by
Image Processor, the Lens Correction batch and the CLI's `batch`
(--recursive --naming --start-serial --stop-on-error --error-log).
The generic form dialog takes an `__order` hint so the Batch dialog is
grouped as Photoshop's (Play, Source, Destination, Errors). chrono
(clock, native only) supplies the local date for the date tokens.
Tests: 9 in batch/tests.rs (tokens and rejected templates, recursive
listing, mirrored output, stop/skip/log, cancelled context, background
job, open-documents source), one CLI test, one form-order test. The
batch_export_options helpers pick the nearest field on a label's row,
since the taller dialog's Quality row now shares a height with the
Layers panel's opacity field. Scorecard AUTO-219-5 done; gaps, parity
and development docs updated.