[Lunar-commits] CVS: theedge/var/lib/lunar/functions modules.lunar, 1.53, 1.54 moonbase.lunar, 1.21, 1.22

Auke Kok sofar at lunar-linux.org
Mon Apr 4 11:12:03 UTC 2005


Update of /var/cvs/lunar/theedge/var/lib/lunar/functions
In directory espresso.foo-projects.org:/home/sofar/active/theedge/var/lib/lunar/functions

Modified Files:
	modules.lunar moonbase.lunar 
Log Message:
Two changes:
reinstate moonbase changelog (was somehow broken)
Make lin a single thread and not call itself but rather call the main() function again (which retains cmdline settings like debug, verbose, etc)


Index: modules.lunar
===================================================================
RCS file: /var/cvs/lunar/theedge/var/lib/lunar/functions/modules.lunar,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -d -r1.53 -r1.54
--- modules.lunar	24 Mar 2005 16:38:59 -0000	1.53
+++ modules.lunar	4 Apr 2005 11:12:00 -0000	1.54
@@ -132,6 +132,7 @@
 # usage   : check_module_index
 # purpose : checks if the index is up-to-date regarding to moonbase
 function check_module_index() {
+(
   debug_msg "check_module_index ($@)"
   if [ ! -e $MODULE_INDEX -o ! -e $DEPENDS_CACHE -o -n "$(find $MOONBASE -type f -name "DETAILS" -cnewer $MODULE_INDEX)" ] ; then
     create_module_index
@@ -140,6 +141,7 @@
   else
     return 1
   fi
+)
 }
 
 

Index: moonbase.lunar
===================================================================
RCS file: /var/cvs/lunar/theedge/var/lib/lunar/functions/moonbase.lunar,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- moonbase.lunar	30 Mar 2005 11:25:53 -0000	1.21
+++ moonbase.lunar	4 Apr 2005 11:12:01 -0000	1.22
@@ -45,14 +45,16 @@
   push_uniq_id
 
   if download_module $MODULE ; then
-    echo -e "${MESSAGE_COLOR}Preparing to install ${FILE_COLOR}${SOURCE}" \
+    message "${MESSAGE_COLOR}Preparing to install ${FILE_COLOR}${SOURCE}" \
             "${DEFAULT_COLOR}${MESSAGE_COLOR}...${DEFAULT_COLOR}"       &&
     mv $SYSTEM_MOONBASE/zlocal/ /var/lib/lunar/.zlocal-backup    &&
     rm -rf $SYSTEM_MOONBASE                                      &&
+	TMP_MODULE_INDEX=$(temp_create "temp.module.index")          &&
+	cp $MODULE_INDEX $TMP_MODULE_INDEX                           &&
     lrm moonbase                                                 &&
     mkdir $SYSTEM_MOONBASE                                       &&
     mv /var/lib/lunar/.zlocal-backup $SYSTEM_MOONBASE/zlocal     &&
-    echo -e "${MESSAGE_COLOR}Extracting ${FILE_COLOR}${SOURCE}" \
+    message "${MESSAGE_COLOR}Extracting ${FILE_COLOR}${SOURCE}" \
             "${DEFAULT_COLOR}${MESSAGE_COLOR}...${DEFAULT_COLOR}"       &&
     bzcat $SOURCE_CACHE/$SOURCE | tar xv -C /var/lib/lunar | \
           sed "s:^:/var/lib/lunar/:g" > $INSTALL_LOGS/$MODULE-$VERSION  &&
@@ -61,7 +63,7 @@
 
     if [ "$OUTCOME" == "success" ] ; then
       echo "$MD5SUM_LOGS/$MODULE-$VERSION" >> $INSTALL_LOGS/$MODULE-$VERSION
-      echo -e "${MESSAGE_COLOR}Created ${FILE_COLOR}$INSTALL_LOGS/$MODULE-$VERSION" \
+      message "${MESSAGE_COLOR}Created ${FILE_COLOR}$INSTALL_LOGS/$MODULE-$VERSION" \
               "${DEFAULT_COLOR}${MESSAGE_COLOR}${DEFAULT_COLOR}"
   
       # create an md5sum log
@@ -72,9 +74,10 @@
     
       add_module $MODULE installed $VERSION $(du -hs $SYSTEM_MOONBASE | cut -f1)
       # get ready to regenerate the module index cache file
-      check_module_index
+	  check_module_index
       update_plugins
       display_moonbase_changes
+	  temp_destroy $TMP_MODULE_INDEX
     fi
   else
     OUTCOME=failed



More information about the Lunar-commits mailing list