cookutils rev 806

cooker.cgi: fix package search
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun Jul 03 11:44:55 2016 +0200 (2016-07-03)
parents eb765a8c3872
children ca8a6e2c923e
files web/cooker.cgi
line diff
     1.1 --- a/web/cooker.cgi	Sun Jul 03 11:30:30 2016 +0200
     1.2 +++ b/web/cooker.cgi	Sun Jul 03 11:44:55 2016 +0200
     1.3 @@ -223,12 +223,14 @@
     1.4  		echo "<h2>Package: $pkg</h2>"
     1.5  
     1.6  		# Define cook variables for syntax highlighter
     1.7 -		. "$WOK/$pkg/receipt"
     1.8 -		_wok='/home/slitaz/wok'
     1.9 -		_src="$_wok/$pkg/source/$PACKAGE-$VERSION"
    1.10 -		_install="$_wok/$pkg/install"
    1.11 -		_fs="$_wok/$pkg/taz/$PACKAGE-$VERSION/fs"
    1.12 -		_stuff="$_wok/$pkg/stuff"
    1.13 +		if [ -s "$WOK/$pkg/receipt" ]; then
    1.14 +			. "$WOK/$pkg/receipt"
    1.15 +			_wok='/home/slitaz/wok'
    1.16 +			_src="$_wok/$pkg/source/$PACKAGE-$VERSION"
    1.17 +			_install="$_wok/$pkg/install"
    1.18 +			_fs="$_wok/$pkg/taz/$PACKAGE-$VERSION/fs"
    1.19 +			_stuff="$_wok/$pkg/stuff"
    1.20 +		fi
    1.21  
    1.22  		# Package info.
    1.23  		echo '<div id="info">'