From 2d6275f465c1805019c591f87b259ca4d462ae8b Mon Sep 17 00:00:00 2001 From: Nathan Woodburn <github@nathan.woodburn.au> Date: Fri, 28 Mar 2025 16:23:44 +1100 Subject: [PATCH] fix: Also symlink files starting with . --- dotfiles.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) 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")