tazpkg rev 517
tazpkg: Fixed PACKAGE_FILE to not cause '/usr/bin/tazpkg: cd: line 46: can't cd to .' errors. This happened cause dirname just equal '.' if there is no folder in $PACKAGE variable. This fix shouldn't cause any problems anyways.
| author | Christopher Rogers <slaxemulator@gmail.com> | 
|---|---|
| date | Sun Jul 10 21:38:15 2011 +0000 (2011-07-10) | 
| parents | 35fbd099024d | 
| children | 573328aaa1e2 | 
| files | tazpkg | 
   line diff
1.1 --- a/tazpkg Sun Jun 26 08:35:00 2011 +0000 1.2 +++ b/tazpkg Sun Jul 10 21:38:15 2011 +0000 1.3 @@ -42,8 +42,9 @@ 1.4 # and actions. 1.5 COMMAND=$1 1.6 PACKAGE=${2%/} 1.7 -[ -n "$PACKAGE" ] && 1.8 -PACKAGE_FILE="$(cd $(dirname $PACKAGE) ; pwd)/$(basename $PACKAGE)" 1.9 +PACKAGE_DIR="$(dirname $PACKAGE)" 1.10 +[ -n "$PACKAGE" -a "$PACKAGE_DIR" != "." ] && 1.11 +PACKAGE_FILE="$(cd $PACKAGE_DIR ; pwd)/${PACKAGE##*/}" 1.12 if [ -f "$PACKAGE" ]; then 1.13 # Set pkg basename for install, extract 1.14 PACKAGE=$(basename ${PACKAGE%.tazpkg} 2>/dev/null)