Browse Source

Keep original mtime

master
Pekka Helenius 6 months ago
parent
commit
6831eab56a
2 changed files with 5 additions and 0 deletions
  1. +3
    -0
      4_scripts/imagetools_02_dualiso.sh
  2. +2
    -0
      4_scripts/imagetools_03_raw_resolution-baseline.sh

+ 3
- 0
4_scripts/imagetools_02_dualiso.sh View File

@ -46,6 +46,7 @@ while \
do
INPUT="${1}"
INPUT_MTIME=$(stat -c "%Y" "${INPUT}")
OLDFILE_CR2=$(basename "${INPUT}")
# Once we do this, it's very clear which kind of CR2 file we're talking about here.
@ -82,6 +83,8 @@ do
# Add Subject=Dual-ISO tag for every Dual ISO CR2 file.
echo "Writing new EXIF/XMP tag Subject: Dual ISO CR2"
exiftool -xmp:subject="Dual ISO CR2" "${INPUT_DIR}/${NEWFILE_CR2}" -overwrite_original
touch --date=@"${INPUT_MTIME}" "${INPUT_DIR}/${NEWFILE_CR2}"
touch --date=@"${INPUT_MTIME}" "${INPUT_DIR}/converted_dual_iso/${NEWFILE_DNG}"
fi
fi


+ 2
- 0
4_scripts/imagetools_03_raw_resolution-baseline.sh View File

@ -59,6 +59,7 @@ do
# Values that change during the while loop (differ from file to file)
INPUT="${1}"
INPUT_MTIME=$(stat -c "%Y" "${INPUT}")
INPUT_BASENAME=$(basename "${INPUT}" | cut -f 1 -d '.')
@ -476,6 +477,7 @@ do
mv "${INPUT}" "${NEWFILE}"
exiftool '-FileName<DateTimeOriginal' -d '%Y%m%d-%f%%-c.%%e' "${NEWFILE}"
#touch --date=@"${INPUT_MTIME}" "${NEWFILE}"
if [[ "${2}" != "" ]]; then
echo "Moving to the next file."


Loading…
Cancel
Save