diff --git a/dotfiles.sh b/dotfiles.sh index c63bd04..f9236be 100755 --- a/dotfiles.sh +++ b/dotfiles.sh @@ -15,8 +15,12 @@ create_symlinks() { # Create the target directory if it doesn't exist mkdir -p "$target_dir" - # For each file - for file in "$src_dir"/*; do + # Process all files, including hidden ones + local files=("$src_dir"/* "$src_dir"/.[!.]*) + for file in "${files[@]}"; do + # Skip if the file doesn't exist (can happen if no hidden files) + [ -e "$file" ] || continue + echo "Processing: $file" # Get the file name local file_name=$(basename "$file")