From 84cf6798770fd74c9f977e9719a4be9a3170454f Mon Sep 17 00:00:00 2001 From: Peter Stone Date: Mon, 23 Jan 2012 16:30:52 -0500 Subject: [PATCH] force symlink creation to workaround moved/deleted link targets --- bin/home-sync | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/home-sync b/bin/home-sync index aea3f74..5ccd1e6 100755 --- a/bin/home-sync +++ b/bin/home-sync @@ -13,7 +13,8 @@ main() { backupAndReplace() { [ -e $HOME/.$1 ] && mv -f $HOME/.$1 $ROOT/backups/$1 - ln -s $ROOT/dot-files/$1 $HOME/.$1 + # this needs to be forced because -e returns false for a dangling symlink + ln -sf $ROOT/dot-files/$1 $HOME/.$1 } main