Files
HotLunches/reseller-images.sh
T
2026-10-19 15:22:52 -07:00

38 lines
556 B
Bash

#!/bin/sh
RESELLERS="esns pitapit-ottawa"
for reseller in $RESELLERS
do
if [ "$reseller" = "esns" ]
then
subpath="esns"
fi
if [ "$reseller" = "pitapit-ottawa" ]
then
subpath="00000410"
fi
if [ "$subpath" = "" ]
then
echo "ERROR: $reseller subpath"
exit
fi
for code in `php files/getcodes.php $reseller`
do
if [ "$code" != "$subpath" ]
then
echo $code
cp files/$code/product_images/* files/$subpath/product_images
fi
done
subpath=""
echo ""
done