aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>2007-01-31 23:23:48 +0000
committerrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>2007-01-31 23:23:48 +0000
commit334bf2308836e855ed6661ba1c129f7fd5b200a2 (patch)
tree4573246a346d8ae375090b29f7634c3a8a7448c5 /lib
parent52f5dc20a540a26dd3661358c780bc1466ebe7f7 (diff)
downloadsimplepkg-334bf2308836e855ed6661ba1c129f7fd5b200a2.tar.gz
simplepkg-334bf2308836e855ed6661ba1c129f7fd5b200a2.tar.bz2
simplaret: file retrieval enhancements
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@135 04377dda-e619-0410-9926-eae83683ac58
Diffstat (limited to 'lib')
-rw-r--r--lib/common.sh13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/common.sh b/lib/common.sh
index a140ccb..8647945 100644
--- a/lib/common.sh
+++ b/lib/common.sh
@@ -193,6 +193,7 @@ function eval_config {
ROOT_PRIORITY="`eval_parameter ROOT_PRIORITY patches slackware extra testing pasture`"
SIMPLARET_PURGE_WEEKS="`eval_parameter SIMPLARET_PURGE_WEEKS 0`"
FTP_TOOL="`eval_parameter FTP_TOOL wget`"
+ HTTP_TOOL="`eval_parameter HTTP_TOOL wget`"
CONNECT_TIMEOUT="`eval_parameter CONNECT_TIMEOUT 0`"
SIMPLARET_CLEAN="`eval_boolean_parameter SIMPLARET_CLEAN 1`"
@@ -239,6 +240,18 @@ function eval_config {
VERSION="$DEFAULT_VERSION"
fi
+ if [ "$FTP_TOOL" != "wget" ] || [ "$FTP_TOOL" != "curl" ] || [ "$FTP_TOOL" != "ncftpget" ]; then
+ echo "$1 configuration error: invalid value $FTP_TOOL for config parameter FTP_TOOL"
+ echo "$1 assuming value \"wget\" for variable FTP_TOOL"
+ FTP_TOOL="wget"
+ fi
+
+ if [ "$HTTP_TOOL" != "wget" ] || [ "$HTTP_TOOL" != "curl" ]; then
+ echo "$1 configuration error: invalid value $HTTP_TOOL for config parameter HTTP_TOOL"
+ echo "$1 assuming value \"wget\" for variable HTTP_TOOL"
+ HTTP_TOOL="wget"
+ fi
+
if which $SIMPLARET &> /dev/null; then
if [ "$SIMPLARET_UPDATE" == "1" ]; then
if [ "$2" == "-u" ]; then