mirror of
https://github.com/sbopkg/sbopkg
synced 2024-11-12 21:10:21 +03:00
remove the -O option from wget since that was causing a few headaches and potential for more; instead create a temporary SRCDIR/download where the wget occurs and the file is then moved to SRCDIR. I am leaving the older stuff commented out for the time being while this is tested; also remove some cruft.
This commit is contained in:
parent
7c86b0aa35
commit
665e7277ea
@ -1054,18 +1054,19 @@ if [ ! -e $PKGPATH/$SRCNAME ]; then
|
|||||||
if [ -e $SRCDIR/$SRCNAME ]; then
|
if [ -e $SRCDIR/$SRCNAME ]; then
|
||||||
ln -s $SRCDIR/$SRCNAME $LOCALREPO/$SLACKVER/$PKGPATH/$SRCNAME
|
ln -s $SRCDIR/$SRCNAME $LOCALREPO/$SLACKVER/$PKGPATH/$SRCNAME
|
||||||
else
|
else
|
||||||
cd $SRCDIR
|
mkdir -p $SRCDIR/download
|
||||||
DOWNLOADFILE=$(echo $DOWNLOAD | sed -e 's/^.*\///g;s/\%2B/+/g')
|
cd $SRCDIR/download
|
||||||
if [ "$PKG" = "django" ]; then
|
#DOWNLOADFILE=$(echo $DOWNLOAD | sed -e 's/^.*\///g;s/\%2B/+/g')
|
||||||
DOWNLOADFILE=$SRCNAME
|
#if [ "$PKG" = "django" ]; then
|
||||||
fi
|
# DOWNLOADFILE=$SRCNAME
|
||||||
#wget -c -t 5 -T $TIMEOUT --progress=bar $DOWNLOAD -O $DOWNLOADFILE || rm -rf $TMP/sbopkg_build.lck
|
#fi
|
||||||
# The above line was the old, default code. The line below is
|
#wget $WGETFLAGS $DOWNLOAD -O $DOWNLOADFILE >> $SBOPKGOUTPUT & echo "$!" >> $TMP/sbopkgpidlist 2>>$SBOPKGOUTPUT
|
||||||
# the new addition to capture PID's, allowing a clean abort
|
wget $WGETFLAGS $DOWNLOAD >> $SBOPKGOUTPUT & echo "$!" >> $TMP/sbopkgpidlist 2>>$SBOPKGOUTPUT
|
||||||
# when a user presses Control-C.
|
|
||||||
wget $WGETFLAGS $DOWNLOAD -O $DOWNLOADFILE >> $SBOPKGOUTPUT & echo "$!" >> $TMP/sbopkgpidlist 2>>$SBOPKGOUTPUT
|
|
||||||
wait
|
wait
|
||||||
|
DOWNLOADFILE=$(ls *)
|
||||||
|
mv $DOWNLOADFILE $SRCDIR/
|
||||||
cd -
|
cd -
|
||||||
|
rm -rf $SRCDIR/download
|
||||||
ln -s $SRCDIR/$SRCNAME $LOCALREPO/$SLACKVER/$PKGPATH/$SRCNAME
|
ln -s $SRCDIR/$SRCNAME $LOCALREPO/$SLACKVER/$PKGPATH/$SRCNAME
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user