aboutsummaryrefslogtreecommitdiffstats
path: root/bash_include
diff options
context:
space:
mode:
authorTing-Wei Lan <lantw44@gmail.com>2014-08-16 00:33:27 +0800
committerTing-Wei Lan <lantw44@gmail.com>2014-08-16 00:33:27 +0800
commitdcff8a66e131e9a6768c79fce450de791f7b90b7 (patch)
tree15c80d39aadacebc8cea29f4f98e097c5a07d3e6 /bash_include
parent56d9e6abc1b16ba15a1a2946a97660b10c5f622a (diff)
downloadconfigfile-dcff8a66e131e9a6768c79fce450de791f7b90b7.tar
configfile-dcff8a66e131e9a6768c79fce450de791f7b90b7.tar.gz
configfile-dcff8a66e131e9a6768c79fce450de791f7b90b7.tar.bz2
configfile-dcff8a66e131e9a6768c79fce450de791f7b90b7.tar.lz
configfile-dcff8a66e131e9a6768c79fce450de791f7b90b7.tar.xz
configfile-dcff8a66e131e9a6768c79fce450de791f7b90b7.tar.zst
configfile-dcff8a66e131e9a6768c79fce450de791f7b90b7.zip
bash_include: 修正 mvfile 在 symlink 指向目標不存在時的錯誤判斷bash_include-20140816
Diffstat (limited to 'bash_include')
-rw-r--r--bash_include2
1 files changed, 1 insertions, 1 deletions
diff --git a/bash_include b/bash_include
index 01cfc01..0dafccc 100644
--- a/bash_include
+++ b/bash_include
@@ -1297,7 +1297,7 @@ function mvfile ()
local -i i=0
while [ "${arglist[$i]}" ]
do
- if [ "$nocheck" = "0" ] && [ '!' -e "${arglist[$i]}" ]
+ if [ "$nocheck" = "0" ] && [ '!' -e "${arglist[$i]}" ] && [ '!' -h "${arglist[$i]}" ]
then
printf "\e[33mWarning\e[m: ${arglist[$i]} does not exist. (Use -n to override)\n"
i=$i+1