From f74fb5893b7d2950378b25dea0ed46891181c8ec Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Tue, 17 Jan 2023 00:09:51 +0300 Subject: [PATCH] started moving away from legacy buildcache command -- process-archive.sh now will use ig by default. Signed-off-by: Alex A. Naanou --- .../media/img/my/work/process-archive.sh | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/Viewer/archive/media/img/my/work/process-archive.sh b/Viewer/archive/media/img/my/work/process-archive.sh index ad52036c..8249fcce 100755 --- a/Viewer/archive/media/img/my/work/process-archive.sh +++ b/Viewer/archive/media/img/my/work/process-archive.sh @@ -328,15 +328,24 @@ fi # build cache... if [ -z $SKIP_CACHE ] ; then - # a little tweak to make build cache work... - export PYTHONIOENCODING=UTF-8 + + # ig... + if ! [ -z `command -v ig` ] ; then + CACHE="ig init" + # buildcache (legacy)... + elif [ -z `command -v buildcache` ] ; then + # a little tweak to make build cache work... + export PYTHONIOENCODING=UTF-8 + CACHE=buildcache + fi + #if [ -z $TOTAL ] ; then # export TOTAL=`find . -path '*hi-res (RAW)/*.jpg' | wc -l` #fi if ! [ -z "$COMMON_PREVIEWS" ] && [ -e "./$COMMON_PREVIEWS/preview (RAW)" ] ; then - buildcache "./$COMMON_PREVIEWS/preview (RAW)" + $CACHE "./$COMMON_PREVIEWS/preview (RAW)" else - find . -type d -name 'preview (RAW)' -exec buildcache "{}" \; + find . -type d -name 'preview (RAW)' -exec $CACHE "{}" \; fi fi