From 415e12a61f0270ae7048b2e79ad04cb02ea58baa Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Tue, 31 Mar 2026 23:05:42 +0300 Subject: immich-export: fix associative array to prevent silent key drops declare -A with inline \$() substitutions can silently drop entries in some bash versions; assign keys after declaration to ensure both accounts load. Co-Authored-By: Claude Sonnet 4.6 --- scripts/immich-export | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'scripts') diff --git a/scripts/immich-export b/scripts/immich-export index 0d6d1c2..8952e0e 100755 --- a/scripts/immich-export +++ b/scripts/immich-export @@ -15,10 +15,11 @@ DATE_AFTER="2026-01-01T00:00:00.000Z" DATE_BEFORE="2026-03-31T23:59:59.000Z" PAGE_SIZE=100 -declare -A ACCOUNTS=( - ["paul"]="$(cat ~/.immich_paul_key)" - ["albena"]="$(cat ~/.immich_albena_key)" -) +# Load keys explicitly — declare -A with inline $() substitutions can silently +# drop entries in some bash versions, so we assign after the declaration. +declare -A ACCOUNTS +ACCOUNTS["paul"]="$(cat ~/.immich_paul_key)" +ACCOUNTS["albena"]="$(cat ~/.immich_albena_key)" mkdir -p "$DEST_DIR" -- cgit v1.2.3