Эх сурвалжийг харах

Fix get_sync_list failing with pipefail when optional files missing

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
G. Capella 1 өдөр өмнө
parent
commit
0da7766efc
1 өөрчлөгдсөн 4 нэмэгдсэн , 4 устгасан
  1. 4 4
      start

+ 4 - 4
start

@@ -34,12 +34,12 @@ get_groups() {
 # Get combined sync list (common + groups + host-specific, deduplicated)
 get_sync_list() {
     {
-        cat "$script_dir/to_sync" 2>/dev/null
+        cat "$script_dir/to_sync" 2>/dev/null || true
         while IFS= read -r group; do
-            cat "$script_dir/to_sync.@$group" 2>/dev/null
+            cat "$script_dir/to_sync.@$group" 2>/dev/null || true
         done < <(get_groups)
-        cat "$script_dir/to_sync.$hostname_id" 2>/dev/null
-    } | grep -v '^\s*$' | sort -u
+        cat "$script_dir/to_sync.$hostname_id" 2>/dev/null || true
+    } | grep -v '^\s*$' | sort -u || true
 }
 
 # Resolve source path: common -> groups (alpha) -> host-specific (last wins)