migrate-seasons.sh: add --cam flag, include Summer in search

--cam NAME overrides SUNRISE_CAM so the script can be used for any
camera (e.g. north).  Summer is now included in the find targets so
any ASTRO_YEAR=2025 Summer clips (Summer 2026) are also migrated.

https://claude.ai/code/session_01C4jbd3waXG3eKZYbGUjLUQ
This commit is contained in:
Claude
2026-04-20 15:05:15 +00:00
parent 8ba0619ead
commit 04809cfe90
+11 -6
View File
@@ -29,15 +29,19 @@ source "$SCRIPT_DIR/sky-cam.conf"
DRY_RUN=false
OLD_ROOT="$HOME/drives/local-2tb/movies/sunrise"
CAM=""
for arg in "$@"; do
case "$arg" in
--dry-run) DRY_RUN=true ;;
*) OLD_ROOT="$arg" ;;
while [[ $# -gt 0 ]]; do
case "$1" in
--dry-run) DRY_RUN=true ;;
--cam) shift; CAM="$1" ;;
--cam=*) CAM="${1#--cam=}" ;;
*) OLD_ROOT="$1" ;;
esac
shift
done
CAM="$SUNRISE_CAM"
[ -z "$CAM" ] && CAM="$SUNRISE_CAM"
NEW_ROOT="$MOVIES_DIR/$CAM/2025"
echo "Old archive : $OLD_ROOT"
@@ -91,6 +95,7 @@ while IFS= read -r -d '' src; do
done < <(find \
"$OLD_ROOT/Spring" \
"$OLD_ROOT/Summer" \
"$OLD_ROOT/Winter" \
"$OLD_ROOT/Autumn" \
-name "*-final.mp4" -print0 2>/dev/null | sort -z)
@@ -117,7 +122,7 @@ $DRY_RUN && echo "Re-run without --dry-run to move the files." && echo ""
echo "Next steps:"
echo " 1. Build montages for completed movements:"
echo " ./montage-mvt.sh 2026-04-19 $CAM # Spring Mvt1"
echo " ./montage-mvt.sh 2026-04-19 $CAM # Spring Mvt1 (today is last day)"
echo " ./montage-mvt.sh 2026-01-18 $CAM # Winter Mvt1"
echo " ./montage-mvt.sh 2026-02-16 $CAM # Winter Mvt2"
echo " ./montage-mvt.sh 2026-03-19 $CAM # Winter Mvt3"