Accepted patch that prevents extra downloads of setup.bz2
git-svn-id: https://apt-cyg.googlecode.com/svn/trunk@11 f2a461e8-04e4-11de-bcc6-d9108be23e13
This commit is contained in:
parent
e81c40cac2
commit
cbff7c94a1
27
apt-cyg
27
apt-cyg
|
@ -89,22 +89,25 @@ function findworkspace()
|
|||
|
||||
function getsetup()
|
||||
{
|
||||
touch setup.ini
|
||||
mv setup.ini setup.ini-save
|
||||
wget $mirror/setup.bz2
|
||||
if test -e setup.bz2 && test $? -eq 0
|
||||
if test "$noscripts" == "0"
|
||||
then
|
||||
bunzip2 setup.bz2
|
||||
mv setup setup.ini
|
||||
echo Updated setup.ini
|
||||
else
|
||||
wget $mirror/setup.ini
|
||||
if test -e setup.ini && test $? -eq 0
|
||||
touch setup.ini
|
||||
mv setup.ini setup.ini-save
|
||||
wget $mirror/setup.bz2
|
||||
if test -e setup.bz2 && test $? -eq 0
|
||||
then
|
||||
bunzip2 setup.bz2
|
||||
mv setup setup.ini
|
||||
echo Updated setup.ini
|
||||
else
|
||||
mv setup.ini-save setup.ini
|
||||
echo Error updating setup.ini, reverting
|
||||
wget $mirror/setup.ini
|
||||
if test -e setup.ini && test $? -eq 0
|
||||
then
|
||||
echo Updated setup.ini
|
||||
else
|
||||
mv setup.ini-save setup.ini
|
||||
echo Error updating setup.ini, reverting
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue