From f152447a0aaf7b47ea44f41ce7317f844d12ad7d Mon Sep 17 00:00:00 2001 From: Brian Zalewski Date: Sat, 3 Sep 2022 07:38:09 +0000 Subject: [PATCH] Update dotfiles/.local/bin/install-dotfiles --- dotfiles/.local/bin/install-dotfiles | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dotfiles/.local/bin/install-dotfiles b/dotfiles/.local/bin/install-dotfiles index ce4e2aa5..cf82dad7 100644 --- a/dotfiles/.local/bin/install-dotfiles +++ b/dotfiles/.local/bin/install-dotfiles @@ -33,8 +33,10 @@ fi # Copy dotfile folders while read DOTFILE_FOLDER; do BASENAME_FOLDER="$(basename "$DOTFILE_FOLDER")" - echo "Folder -> $BASENAME_FOLDER" - cp -rf "$DOTFILE_FOLDER" "$HOME/$BASENAME_FOLDER" + if [ ! -d "$HOME/$BASENAME_FOLDER" ]; then + mkdir -p "$HOME/$BASENAME_FOLDER" + fi + cp -rf "$DOTFILE_FOLDER/*" "$HOME/$BASENAME_FOLDER" done < <(find /usr/src/professor-dotfiles/dotfiles -maxdepth 1 -mindepth 1 -type d) # Copy dotfile files