Rename and move images according to date

Revision as of 01:36, 13 August 2016 by Sam (talk | contribs) (Imported from text file)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

My simple script that I use to shift files into my (ownCloud-backed) archiving system:


if [ ! -d "$1" ]; then
  echo "Error: first parameter must be a directory" >&2
  echo "Usage: "$(basename $0)" 

    echo "       where 
    is an existing directory from which to import images"
      exit 1
    exiftool '-FileName<DateTimeOriginal' -d $DEST"/%Y/%m_%b/%d/%Y-%m-%d_%H%M%%+c.%%e" "$1"

Retrieved from ‘