aboutsummaryrefslogtreecommitdiff
path: root/trunk/lib/common.sh
diff options
context:
space:
mode:
Diffstat (limited to 'trunk/lib/common.sh')
-rw-r--r--trunk/lib/common.sh24
1 files changed, 12 insertions, 12 deletions
diff --git a/trunk/lib/common.sh b/trunk/lib/common.sh
index cb88ec7..275c355 100644
--- a/trunk/lib/common.sh
+++ b/trunk/lib/common.sh
@@ -324,11 +324,11 @@ function search_default_template {
if [ -e "$BASE_CONF/default.template" ]; then
TEMPLATE_BASE="$BASE_CONF/default"
echo $BASENAME using default template
- elif [ -e "$BASE_CONF/templates/default.template" ]; then
- TEMPLATE_BASE="$BASE_CONF/templates/default"
+ elif [ -e "$TEMPLATE_FOLDER/default.template" ]; then
+ TEMPLATE_BASE="$TEMPLATE_FOLDER/default"
echo $BASENAME: using default template
- elif [ -e "$BASE_CONF/templates/default/default.template" ]; then
- TEMPLATE_BASE="$BASE_CONF/templates/default/default"
+ elif [ -e "$TEMPLATE_FOLDER/default/default.template" ]; then
+ TEMPLATE_BASE="$TEMPLATE_FOLDER/default/default"
echo $BASENAME: using default template
elif [ -e "$BASE_CONF/defaults/templates/default/default.template" ]; then
TEMPLATE_BASE="$BASE_CONF/defaults/templates/default"
@@ -350,8 +350,8 @@ function search_template {
# templates can be stored either on
#
# - $BASE_CONF/template_name.template
- # - $BASE_CONF/templates/template_name.template
- # - $BASE_CONF/templates/template_name/template_name.template
+ # - $TEMPLATE_FOLDER/template_name.template
+ # - $TEMPLATE_FOLDER/template_name/template_name.template
#
# also, there's a folder for "oficial" simplepkg templates,
# $BASE_CONF/defaults/templates/ and you can override any template
@@ -361,10 +361,10 @@ function search_template {
if [ -f "$BASE_CONF/$1.template" ]; then
TEMPLATE_BASE="$BASE_CONF/$1"
- elif [ -f "$BASE_CONF/templates/$1.template" ]; then
- TEMPLATE_BASE="$BASE_CONF/templates/$1"
- elif [ -f "$BASE_CONF/templates/$1/$1.template" ]; then
- TEMPLATE_BASE="$BASE_CONF/templates/$1/$1"
+ elif [ -f "$TEMPLATE_FOLDER/$1.template" ]; then
+ TEMPLATE_BASE="$TEMPLATE_FOLDER/$1"
+ elif [ -f "$TEMPLATE_FOLDER/$1/$1.template" ]; then
+ TEMPLATE_BASE="$TEMPLATE_FOLDER/$1/$1"
elif [ -f "$BASE_CONF/defaults/templates/$1/$1.template" ]; then
TEMPLATE_BASE="$BASE_CONF/defaults/templates/$1/$1"
else
@@ -373,9 +373,9 @@ function search_template {
if [ "$TEMPLATE_STORAGE_STYLE" == "simplepkg-folder" ]; then
TEMPLATE_BASE="$BASE_CONF/$1"
elif [ "$TEMPLATE_STORAGE_STYLE" == "templates-folder" ]; then
- TEMPLATE_BASE="$BASE_CONF/templates/$1"
+ TEMPLATE_BASE="$TEMPLATE_FOLDER/$1"
else
- TEMPLATE_BASE="$BASE_CONF/templates/$1/$1"
+ TEMPLATE_BASE="$TEMPLATE_FOLDER/$1/$1"
fi
elif [ "$2" == "--update" ]; then
return 1