commit 9986e1c6fd301f125b90405b1eca58efc3e79025 parent 5566363a9603aa7210c43a51a6050cd1aa88fece Author: Xiaodong Xu <[email protected]> Date: Tue Apr 17 22:11:10 +0800 Fix symlink loop error Diffstat:
_vim/_vim | | | 2 | -- |
vimenv | | | 4 | ++++ |
diff --git a/_vim/_vim b/_vim/_vim @@ -1 +0,0 @@ -/home/xiaodong/code/vimenv/_vim- \ No newline at end of file diff --git a/vimenv b/vimenv @@ -23,6 +23,10 @@ def init FileUtils.mv(target, bak) end + if File.symlink?(target) + FileUtils.rm(target) + end + puts "Symlinking #{orig} to #{target}" FileUtils.symlink(orig, target, force: true) end