tazwok diff tazwok @ rev 559
tazwok: typos
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Tue Nov 09 11:24:59 2021 +0000 (2021-11-09) |
parents | 61b3b07955df |
children |
line diff
1.1 --- a/tazwok Tue Feb 26 08:31:13 2019 +0100 1.2 +++ b/tazwok Tue Nov 09 11:24:59 2021 +0000 1.3 @@ -232,7 +232,7 @@ 1.4 # genpkg_rules: it maybe needs something inside. 1.5 for i in $PACKAGE $(look_for_rwanted); do 1.6 sed -n '/^genpkg_rules\(\)/','/^}/'p $WOK/$i/receipt | \ 1.7 - fgrep -q '$src' && tazwok_warning "Sources will not be removed \ 1.8 + fgrep -q "$src" && tazwok_warning "Sources will not be removed \ 1.9 because $i uses \$src in its receipt." && return 1.10 done 1.11 1.12 @@ -613,7 +613,7 @@ 1.13 unset main_version 1.14 fi 1.15 fi 1.16 - if [ ! "$main_version" ] || [ $(grep -q "^$PACKAGE | $VERSION" $INCOMING_REPOSITORY/packages.desc 2>/dev/null) ]; then 1.17 + if [ ! "$main_version" ] || grep -q "^$PACKAGE | $VERSION" $INCOMING_REPOSITORY/packages.desc 2>/dev/null; then 1.18 if [ -f $src_repository/${SOURCE:-$PACKAGE}-${KBASEVER:-$VERSION}.tar.lzma ]; then 1.19 echo -e "$PACKAGE:incoming\t${SOURCE:-$PACKAGE}-${KBASEVER:-$VERSION}.tar.lzma" >> $src_repository/sources.list 1.20 elif [ -f "$src_repository/$TARBALL" ]; then 1.21 @@ -758,7 +758,7 @@ 1.22 fi 1.23 ;; 1.24 svn*|subversion*) 1.25 - if $(echo "$WGET_URL" | fgrep -q svn); then 1.26 + if echo "$WGET_URL" | fgrep -q svn; then 1.27 file=${WGET_URL#svn|} 1.28 else 1.29 file=${WGET_URL#subversion|} 1.30 @@ -779,7 +779,7 @@ 1.31 fi 1.32 ;; 1.33 hg*|mercurial*) 1.34 - if $(echo "$WGET_URL" | fgrep -q hg); then 1.35 + if echo "$WGET_URL" | fgrep -q hg; then 1.36 file=${WGET_URL#hg|} 1.37 else 1.38 file=${WGET_URL#mercurial|} 1.39 @@ -930,13 +930,13 @@ 1.40 for dir in $fs/bin $fs/sbin $fs/usr/bin $fs/usr/sbin $fs/usr/games 1.41 do 1.42 if [ -d "$dir" ]; then 1.43 - find $dir -type f -exec strip -s '{}' 2>/dev/null \; 1.44 + find $dir -type f -exec strip -s '{}' \; 2>/dev/null 1.45 fi 1.46 done 1.47 1.48 # Libraries. 1.49 - find $fs -name "*.so*" -exec strip -s '{}' 2>/dev/null \; 1.50 - find $fs -name "*.a" -exec strip --strip-debug '{}' 2>/dev/null \; 1.51 + find $fs -name "*.so*" -exec strip -s '{}' \; 2>/dev/null 1.52 + find $fs -name "*.a" -exec strip --strip-debug '{}' \; 2>/dev/null 1.53 report end-step 1.54 } 1.55 1.56 @@ -1113,7 +1113,7 @@ 1.57 # Generate md5 of cooking stuff to look for commit later. 1.58 gen_cookmd5 1.59 echo -e "\n# md5sum of cooking stuff :" >> taz/$PACKAGE-$VERSION/receipt 1.60 - cat md5 | sed 's/^/# /' >> taz/$PACKAGE-$VERSION/receipt 1.61 + sed 's/^/# /' >> taz/$PACKAGE-$VERSION/receipt < md5 1.62 1.63 # Create the files.list by redirecting find output. 1.64 report step "Creating the list of files" 1.65 @@ -1306,7 +1306,7 @@ 1.66 1.67 # Look for removed/update packages. 1.68 touch stamp -r packages.list 1.69 - for PACKAGE in $(grep ^[0-9,a-z,A-Z] packages.txt); do 1.70 + for PACKAGE in $(grep '^[0-9,a-z,A-Z]' packages.txt); do 1.71 pkg="$pkg_repository/$(grep -m1 ^$PACKAGE- packages.list).tazpkg" 1.72 if ! [ -f "$pkg" ]; then 1.73 erase_package_info 1.74 @@ -1432,7 +1432,7 @@ 1.75 cd .. && rm -r "$pkg_files_dir" 1.76 1.77 cd $pkg_repository 1.78 - echo $(basename ${pkg%.tazpkg}) >> packages.list 1.79 + basename ${pkg%.tazpkg} >> packages.list 1.80 [ ! "$package_md5" ] && package_md5=$(md5sum $(basename $pkg)) 1.81 echo "$package_md5" >> packages.md5 1.82 unset package_md5 1.83 @@ -1540,7 +1540,7 @@ 1.84 sort_db() 1.85 { 1.86 report step "Generating cookorder.txt" 1.87 - cat $dep_db | sed 's/ \t / /' | while read PACKAGE BUILD_DEPENDS; do 1.88 + sed 's/ \t / /' < $dep_db | while read PACKAGE BUILD_DEPENDS; do 1.89 grep -q ^$PACKAGE$'\t' $wan_db && continue 1.90 1.91 # Replace each BUILD_DEPENDS with a WANTED package by it's 1.92 @@ -1826,7 +1826,7 @@ 1.93 if [ "$cooklist" ]; then 1.94 mv $tmp/dep $tmp/cooklist 1.95 else 1.96 - cat $tmp/dep | sort -u 1.97 + sort -u < $tmp/dep 1.98 fi 1.99 rm -f $tmp/dep $tmp/list 1.100 sort -o $dep_db $dep_db 1.101 @@ -2281,7 +2281,7 @@ 1.102 SLITAZ_DIR=$SLITAZ_DIR 1.103 SLITAZ_VERSION=$SLITAZ_VERSION 1.104 $( [ "$undigest" ] && echo "undigest=$undigest" ) 1.105 -LOCAL_REPOSITORY=$SLITAZ_DIR/$(if [ "$undigest" ]; then echo '$undigest'; else echo '$SLITAZ_VERSION'; fi) 1.106 +LOCAL_REPOSITORY=$SLITAZ_DIR/$(if [ "$undigest" ]; then echo "$undigest"; else echo "$SLITAZ_VERSION"; fi) 1.107 chroot_dir=\$LOCAL_REPOSITORY/chroot 1.108 1.109 # Default scripts path (these scripts are added to the 1.110 @@ -2355,7 +2355,7 @@ 1.111 for i in $(fgrep -l PROVIDE $WOK/*/receipt); do 1.112 . $i 1.113 case " $PROVIDE " in 1.114 - *\ $1\ *|*\ $1:*) echo $(basename $(dirname $i));; 1.115 + *\ $1\ *|*\ $1:*) basename $(dirname $i);; 1.116 esac 1.117 done 1.118 } 1.119 @@ -2691,7 +2691,7 @@ 1.120 echo -n "$PACKAGE " 1.121 echo -en "\033[24G $VERSION" 1.122 echo -e "\033[42G $CATEGORY" 1.123 - packages=$(($PACKAGEs+1)) 1.124 + packages=$(($packages+1)) 1.125 done 1.126 horizontal_line 1.127 echo "$packages packages found for : $2" 1.128 @@ -3081,7 +3081,7 @@ 1.129 fi 1.130 done 1.131 horizontal_line 1.132 - echo "Maintainers: `cat /tmp/slitaz-maintainers | wc -l`" 1.133 + echo "Maintainers: `wc -l < /tmp/slitaz-maintainers`" 1.134 echo "" 1.135 # Remove tmp files 1.136 rm -f /tmp/slitaz-maintainers 1.137 @@ -3089,7 +3089,7 @@ 1.138 maintained-by) 1.139 # Search for packages maintained by a contributor. 1.140 get_tazwok_config 1.141 - if [ ! -n "$2" ]; then 1.142 + if [ -z "$2" ]; then 1.143 echo "Specify a name or email of a maintainer." >&2 1.144 exit 1 1.145 fi 1.146 @@ -3100,7 +3100,7 @@ 1.147 . $pkg/receipt 1.148 if echo "$MAINTAINER" | fgrep -q "$2"; then 1.149 echo "$PACKAGE" 1.150 - packages=$(($PACKAGEs+1)) 1.151 + packages=$(($packages+1)) 1.152 fi 1.153 done 1.154 horizontal_line 1.155 @@ -3187,8 +3187,8 @@ 1.156 if [ "$missing" ]; then 1.157 pkg=$(ls -1 $WOK) 1.158 else 1.159 - pkg="$({ grep ^[a-zA-Z0-9] $PACKAGES_REPOSITORY/packages.txt 1.160 - grep ^[a-zA-Z0-9] $INCOMING_REPOSITORY/packages.txt 1.161 + pkg="$({ grep '^[a-zA-Z0-9]' $PACKAGES_REPOSITORY/packages.txt 1.162 + grep '^[a-zA-Z0-9]' $INCOMING_REPOSITORY/packages.txt 1.163 } | sort -u)" 1.164 fi 1.165 cooklist=$PACKAGES_REPOSITORY/cooklist 1.166 @@ -3207,8 +3207,8 @@ 1.167 if [ "$missing" ]; then 1.168 pkg=$(ls -1 $WOK) 1.169 else 1.170 - pkg="$({ grep ^[a-zA-Z0-9] $PACKAGES_REPOSITORY/packages.txt 1.171 - grep ^[a-zA-Z0-9] $INCOMING_REPOSITORY/packages.txt 1.172 + pkg="$({ grep '^[a-zA-Z0-9]' $PACKAGES_REPOSITORY/packages.txt 1.173 + grep '^[a-zA-Z0-9]' $INCOMING_REPOSITORY/packages.txt 1.174 } | sort -u)" 1.175 fi 1.176 cooklist=$PACKAGES_REPOSITORY/cooklist 1.177 @@ -3224,8 +3224,8 @@ 1.178 if [ "$missing" ]; then 1.179 pkg=$(ls -1 $WOK) 1.180 else 1.181 - pkg="$({ grep ^[a-zA-Z0-9] $PACKAGES_REPOSITORY/packages.txt 1.182 - grep ^[a-zA-Z0-9] $INCOMING_REPOSITORY/packages.txt 1.183 + pkg="$({ grep '^[a-zA-Z0-9]' $PACKAGES_REPOSITORY/packages.txt 1.184 + grep '^[a-zA-Z0-9]' $INCOMING_REPOSITORY/packages.txt 1.185 } | sort -u)" 1.186 fi 1.187 cooklist=$PACKAGES_REPOSITORY/cooklist