tazwok rev 110
ensure that 'tazwok cmp --text --fakewok' don't remove the wok
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Jan 23 22:51:31 2009 +0000 (2009-01-23) |
parents | 2a0e22536a34 |
children | 39afa4058a9d |
files | tazwok |
line diff
1.1 --- a/tazwok Sun Jan 18 00:24:36 2009 +0100 1.2 +++ b/tazwok Fri Jan 23 22:51:31 2009 +0000 1.3 @@ -1052,12 +1052,12 @@ 1.4 # if $2 is not empty cd into $2. A text packages list can also be gen 1.5 # with the option --text. 1.6 # 1.7 - fakewok="no" 1.8 + fakewok="" 1.9 if [ "$2" == "--text" ]; then 1.10 textlist="yes" 1.11 if [ "$3" == "--fakewok" ]; then 1.12 - fakewok="yes" 1.13 WOK=/tmp/fakewok-$$ 1.14 + fakewok="$WOK" 1.15 mkdir -p $WOK 1.16 for i in $PACKAGES_REPOSITORY/*.tazpkg; do 1.17 (cd $WOK; cpio -i receipt files.list 2>/dev/null) < $i 1.18 @@ -1088,14 +1088,14 @@ 1.19 # Generate packages.txt 1.20 if [ "$textlist" == "yes" ]; then 1.21 gen_textlist 1.22 - [ "$fakewok" == "yes" ] && rm -rf $WOK 1.23 + [ "$fakewok" == "" ] || rm -rf $fakewok 1.24 fi 1.25 echo -n "Creating the raw packages list... " 1.26 ls -1 *.tazpkg > /tmp/packages.list 1.27 sed -i s/'.tazpkg'/''/ /tmp/packages.list 1.28 status 1.29 echo -n "Building the md5sum for all packages... " 1.30 - md5sum * > packages.md5 1.31 + md5sum *.tazpkg > packages.md5 1.32 status 1.33 mv /tmp/packages.list $PACKAGES_REPOSITORY 1.34 echo "================================================================================"