wok diff vim-tiny/receipt @ rev 18730

Quote root dir in post_install
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun Dec 20 15:13:45 2015 +0100 (2015-12-20)
parents 3494cfd4c595
children 6fab3264ba87
line diff
     1.1 --- a/vim-tiny/receipt	Sun Nov 08 14:57:26 2015 +0100
     1.2 +++ b/vim-tiny/receipt	Sun Dec 20 15:13:45 2015 +0100
     1.3 @@ -57,10 +57,8 @@
     1.4  
     1.5  post_install()
     1.6  {
     1.7 -    local root
     1.8 -    root=$1
     1.9      echo "Processing post-install commands..."
    1.10 -    cmd=`readlink $root/bin/vi`
    1.11 +    cmd=$(readlink "$1/bin/vi")
    1.12      if [ ! "$cmd" = "/usr/bin/vim" ]; then
    1.13          echo ""
    1.14          echo "**** Actual VI link : $cmd"
    1.15 @@ -69,7 +67,7 @@
    1.16          if [ "$anser" == "y" ]; then
    1.17              echo ""
    1.18              echo -n "Removing vi link to make a new one pointing on /usr/bin/vim..."
    1.19 -            rm $root/bin/vi && ln -sf $root/usr/bin/vim-tiny $root/bin/vi
    1.20 +            rm "$1/bin/vi" && ln -sf /usr/bin/vim-tiny "$1/bin/vi"
    1.21              status
    1.22          else
    1.23              echo ""
    1.24 @@ -82,5 +80,5 @@
    1.25  {
    1.26  	# restore previous symlink
    1.27  	echo "Processing post-remove commands..."
    1.28 -	ln -sf /bin/busybox $1/bin/vi
    1.29 +	ln -sf /bin/busybox "$1/bin/vi"
    1.30  }