> On 18 Feb 2018, at 17:47, Floyd Anderson <f...@31c0.net> wrote: >> >> $ cat t.sh >> #!/bin/bash >> TMPF=$(mktemp "/tmp/detox_wrapper.$$.XXXXXXXX") >> for f in "$@"; do >> touch -r "$f" "$TMPF" >> detox "$f" >> touch -r "$TMPF" "$f" >> done >> rm -f "$TMPF" > > If I’m not totally wrong, the second `touch` cannot work because the file > that "$f" holds is renamed now. That’s what I mean earlier with iterating a > list or adapt Stroller’s suggestion.
How careless of me. A solution is to use `detox -v` and capture the output. $ touch '1234[]' $ ls '1234[]' 1234[] $ detox -v 1234* Scanning: 1234[] 1234[] -> 1234- $ A bit untidy. Really, detox should be patched to check the date and apply it to the new file. Stroller.