Permalink
Browse files

Better way to reslove a symlink.

  • Loading branch information...
1 parent ab64b8e commit 9bbf8bb3d0047277e3a8549b14c5735c06bb8f58 @weynhamz committed Mar 13, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 dotploy.sh
View
@@ -69,7 +69,7 @@ docheck() {
echo "CHECKING: $dst"
if [ -h $dst ];then
- local csrc=$(stat --printf=%N $dst | sed 's/ -> /\t/g' | cut -f2 | sed 's/^"//g' | sed 's/"$//g')
+ local csrc=$(readlink -f $dst)
if [[ $csrc =~ $DOTSREPO ]];then #whether link to dotsrepo
if [ "$csrc" == "$src" ];then

0 comments on commit 9bbf8bb

Please sign in to comment.