check if $BASE_DIR/etc/$DISTRIBUTION/apt.conf/sources.list already exists,

if not, create new, if yes, leave it untouched
This commit is contained in:
Stephan Hermann 2008-01-22 19:01:44 +01:00
parent a4411984ad
commit 84f00a9165

View File

@ -216,17 +216,20 @@ then
then then
mkdir -p $BASE_DIR/etc/$DISTRIBUTION/apt.conf mkdir -p $BASE_DIR/etc/$DISTRIBUTION/apt.conf
fi fi
echo "deb $ARCHIVE $DISTRIBUTION $COMPONENTS" > $BASE_DIR/etc/$DISTRIBUTION/apt.conf/sources.list if [ ! -e $BASE_DIR/etc/$DISTRIBUTION/apt.conf/sources.list ]
case $DISTRIBUTION in then
dapper|edgy|feisty|gutsy ) echo "deb $ARCHIVE $DISTRIBUTION $COMPONENTS" > $BASE_DIR/etc/$DISTRIBUTION/apt.conf/sources.list
cat >> $BASE_DIR/etc/$DISTRIBUTION/apt.conf/sources.list <<EOF case $DISTRIBUTION in
dapper|edgy|feisty|gutsy )
cat >> $BASE_DIR/etc/$DISTRIBUTION/apt.conf/sources.list <<EOF
deb $ARCHIVE $DISTRIBUTION-security $COMPONENTS deb $ARCHIVE $DISTRIBUTION-security $COMPONENTS
deb $ARCHIVE $DISTRIBUTION-updates $COMPONENTS deb $ARCHIVE $DISTRIBUTION-updates $COMPONENTS
EOF EOF
;; ;;
* ) * )
;; ;;
esac esac
fi
fi fi
if [ -n $DESKTOP_SESSION ] if [ -n $DESKTOP_SESSION ]