rn: Support $HOME with spaces.
This commit is contained in:
parent
28e9986059
commit
fb1c5b18ce
6
rn/rn
6
rn/rn
|
@ -57,8 +57,8 @@ find_rm_dir() {
|
||||||
echo "$1"/.rm
|
echo "$1"/.rm
|
||||||
return 0
|
return 0
|
||||||
else
|
else
|
||||||
if [ "/" == $(readlink -f "$dir") ]; then
|
if [ "/" == "$(readlink -f "$dir")" ]; then
|
||||||
echo $HOME/.rm
|
echo "$HOME"/.rm
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
find_rm_dir "../$dir"
|
find_rm_dir "../$dir"
|
||||||
|
@ -68,4 +68,4 @@ find_rm_dir() {
|
||||||
|
|
||||||
rmdir="$(find_rm_dir .)"
|
rmdir="$(find_rm_dir .)"
|
||||||
mkdir -p "$rmdir"
|
mkdir -p "$rmdir"
|
||||||
mv --backup=numbered "$@" $rmdir
|
mv --backup=numbered "$@" "$rmdir"
|
||||||
|
|
Loading…
Reference in a new issue