spk diff spk-add @ rev 64

spk-archive: be busybox ash compatible
author Christophe Lincoln <pankso@slitaz.org>
date Fri May 18 03:19:51 2012 +0200 (2012-05-18)
parents 17ac07667767
children 63fb720dc777
line diff
     1.1 --- a/spk-add	Thu May 17 23:40:23 2012 +0200
     1.2 +++ b/spk-add	Fri May 18 03:19:51 2012 +0200
     1.3 @@ -285,15 +285,15 @@
     1.4  	local package_name="$1"
     1.5  
     1.6  	# Check if get-Package
     1.7 -	if ! is_package_mirrored $package_name; then
     1.8 +	if mirrored_pkg get-$package_name; then
     1.9  		package_name="get-$package_name"
    1.10 -		AUTOEXEC=true
    1.11 +		exec=true
    1.12  	fi
    1.13  
    1.14  	# Check if package is mirrored
    1.15 -	if ! is_package_mirrored $package_name; then
    1.16 -		gettext "Could not find package on mirror:"; echo " $package_name"
    1.17 -		exit 1
    1.18 +	if ! mirrored_pkg $package_name; then
    1.19 +		gettext "Could not find package on mirror:"
    1.20 +		boldify " $package_name" && exit 1
    1.21  	fi
    1.22  
    1.23  	# package_full=Package-Version
    1.24 @@ -324,8 +324,8 @@
    1.25  
    1.26  	install_package "$CACHE_DIR/$package_full.tazpkg"
    1.27  
    1.28 -	#[ "$AUTOEXEC" ] && chroot $root/ $package_name
    1.29 -	[ "$AUTOEXEC" ] && $package_name $root
    1.30 +	#[ "$exec" ] && chroot $root/ $package_name
    1.31 +	[ "$exec" ] && $package_name $root
    1.32  	update_databases
    1.33  }
    1.34