From 7b385368b0cd926b5a39eb605916843203370a6e Mon Sep 17 00:00:00 2001 From: Thomas Preisner Date: Thu, 27 Jul 2017 14:32:15 +0200 Subject: [PATCH] setup: ask user to continue linking if one symlink couldn't be created --- setup.sh | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/setup.sh b/setup.sh index 93af027..eacba0d 100755 --- a/setup.sh +++ b/setup.sh @@ -14,8 +14,16 @@ link() local dst="$2" if test -e "$dst" && ! test -L "$dst"; then - echo "No symlink $dst" - exit 1 + echo "File $dst exists and is no symlink.\nIgnore and continue? (y/N)" + read answer + case $answer in + [Yy]*) + return + ;; + *) + exit 1 + ;; + esac fi if installed printf; then