Use tqdm for progress bar in photobydate
This commit is contained in:
parent
56ce8d9f87
commit
eb99b40aee
|
@ -168,16 +168,16 @@ suffix() {
|
||||||
|
|
||||||
alias exifcopy="exiftool -tagsFromFile"
|
alias exifcopy="exiftool -tagsFromFile"
|
||||||
photobydate() {
|
photobydate() {
|
||||||
revolver start
|
local imagefiles
|
||||||
for i in ${*:-(#i)*.(JPG|CR[23]|DNG)(N)}; do
|
imagefiles=( ${*:-(#i)*.(JPG|CR[23]|DNG)(N)} )
|
||||||
|
for i in ${imagefiles[@]}; do
|
||||||
if [[ -e $i ]]; then
|
if [[ -e $i ]]; then
|
||||||
revolver update $i
|
dir=$(exiftool -p '$DateTimeOriginal' $i 2>/dev/null | tr ':' '-' | cut -d' ' -f1;)
|
||||||
dir=$(exiftool -p '$DateTimeOriginal' $i | tr ':' '-' | cut -d' ' -f1;)
|
|
||||||
mkdir -p $dir
|
mkdir -p $dir
|
||||||
|
printf "%s\n" ${i:r}.*
|
||||||
mv ${i:r}.* $dir
|
mv ${i:r}.* $dir
|
||||||
fi
|
fi
|
||||||
done
|
done | tqdm --total $#imagefiles --unit=imgs >> /dev/null
|
||||||
revolver stop
|
|
||||||
}
|
}
|
||||||
|
|
||||||
alias mkvidentify="mkvmerge --identify"
|
alias mkvidentify="mkvmerge --identify"
|
||||||
|
|
Loading…
Reference in a new issue