From e4c66a06ff2354fdffa5f9e425a4f28dbd340c52 Mon Sep 17 00:00:00 2001 From: klein panic Date: Sun, 29 Sep 2024 02:31:26 -0400 Subject: [PATCH] Automated update --- auto_git_update.sh | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/auto_git_update.sh b/auto_git_update.sh index 98bd607..bc47037 100755 --- a/auto_git_update.sh +++ b/auto_git_update.sh @@ -39,26 +39,18 @@ check_wifi() { get_repo_dirs() { local valid_dirs=() - echo "Reading directories from $TXT_FILE..." # Debugging line - while IFS= read -r repo_dir; do # Trim whitespace and skip empty lines repo_dir=$(echo "$repo_dir" | xargs) [ -z "$repo_dir" ] && continue - echo "Processing: '$repo_dir'" # Debugging line to show each line being processed - # Check if the directory is valid and contains a .git folder if [ -d "$repo_dir" ] && [ -d "$repo_dir/.git" ]; then - echo "Valid Git repository found: '$repo_dir'" # Debugging line valid_dirs+=("$repo_dir") - else - echo "Invalid directory or not a Git repository: '$repo_dir'" # Debugging line fi done < "$TXT_FILE" - # Ensure the valid_dirs array contains the expected directories - echo "Valid directories: ${valid_dirs[@]}" # Final debug line showing valid directories + # Output only the valid directories without any additional text echo "${valid_dirs[@]}" }