aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>2007-04-06 17:07:54 +0000
committerrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>2007-04-06 17:07:54 +0000
commit285ea9c4487816abb2c0dd80396bc71bb9d9d72a (patch)
treeacf02d85b94cf6438bee8acf00e286d18dbda8b2
parent1c390f05461234f6fbbf27c8a546c75ccef47950 (diff)
downloadsimplepkg-285ea9c4487816abb2c0dd80396bc71bb9d9d72a.tar.gz
simplepkg-285ea9c4487816abb2c0dd80396bc71bb9d9d72a.tar.bz2
search_default_template fix
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@293 04377dda-e619-0410-9926-eae83683ac58
-rw-r--r--trunk/lib/common.sh12
1 files changed, 8 insertions, 4 deletions
diff --git a/trunk/lib/common.sh b/trunk/lib/common.sh
index e856890..778fcc6 100644
--- a/trunk/lib/common.sh
+++ b/trunk/lib/common.sh
@@ -321,14 +321,18 @@ function default_arch {
function search_default_template {
- if [ -e "$BASE_CONF/templates/default.template" ]; then
- TEMPLATE_BASE="$BASE_CONF/templates/default"
- echo $BASENAME: using default template
- elif [ -e "$BASE_CONF/default.template" ]; then
+ 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"
+ echo $BASENAME: using default template
+ elif [ -e "$BASE_CONF/templates/default/default.template" ]; then
+ TEMPLATE_BASE="$BASE_CONF/templates/default/default"
+ echo $BASENAME: using default template
elif [ -e "$BASE_CONF/defaults/templates/default/default.template" ]; then
TEMPLATE_BASE="$BASE_CONF/defaults/templates/default"
+ echo $BASENAME using default template
else
echo $BASENAME: error: default template not found
echo $BASENAME: please create a template using templatepkg