From: W. Trevor King Date: Thu, 27 Sep 2012 11:27:37 +0000 (-0400) Subject: Use relative rather than absolute links. X-Git-Tag: v0.3~16 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=c78363295721cba9bafc1d85c932424afd2d6bc2;p=dotfiles-framework.git Use relative rather than absolute links. This allows a single dotfiles installation to work on NFS-mounted home directories, even if that home directory is mounted in different locations on different machines. --- diff --git a/dotfiles.sh b/dotfiles.sh index 53dbe00..82ff4f7 100755 --- a/dotfiles.sh +++ b/dotfiles.sh @@ -257,7 +257,7 @@ function link_file() echo "link ${TARGET}/${FILE} to ${DOTFILES_DIR}/${REPO}/patched-src/${FILE}" else echo -n 'link ' - "${LN}" -sv "${DOTFILES_DIR}/${REPO}/patched-src/${FILE}" "${TARGET}/${FILE}" || return 1 + "${LN}" -rsv "${DOTFILES_DIR}/${REPO}/patched-src/${FILE}" "${TARGET}/${FILE}" || return 1 fi }