[Lunar-commits] CVS: theedge/var/lib/lunar/functions modules.lunar, 1.46, 1.47 moonbase.lunar, 1.17, 1.18 updatelog.lunar, 1.14, 1.15

Auke Kok sofar at lunar-linux.org
Fri Oct 29 14:17:54 UTC 2004


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 updatelog.lunar 
Log Message:
Removing MOONBASE_MD5 code as I suspect that it screws things up and it's unused anyway.


Index: modules.lunar
===================================================================
RCS file: /var/cvs/lunar/theedge/var/lib/lunar/functions/modules.lunar,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -d -r1.46 -r1.47
--- modules.lunar	25 Oct 2004 19:44:15 -0000	1.46
+++ modules.lunar	29 Oct 2004 14:17:52 -0000	1.47
@@ -30,7 +30,7 @@
 list_sections() {
   debug_msg "list_sections ($@)"
   check_module_index
-  grep -v ^MOONBASE_MD5: $MODULE_INDEX | cut -d: -f2 | sort | uniq
+  cut -d: -f2 < $MODULE_INDEX | sort | uniq
   return 0
 }
 
@@ -102,18 +102,16 @@
   if [ "$MOONBASE" == "/var/lib/lunar/moonbase" ] ; then
     # short way out:
     debug_msg "Quick generating \$MODULE_INDEX..."
-    echo MOONBASE_MD5:$(set_moonbase_md5) > $TMP_INDEX
     grep "/DETAILS$" $INSTALL_LOGS/moonbase-$(installed_version moonbase) | \
         sed -e 's:/DETAILS$::' -e 's:/var/lib/lunar/moonbase/::' -e 's|/|:|' | \
-	awk -F: '{print $2":"$1}' >> $TMP_INDEX
+	awk -F: '{print $2":"$1}' > $TMP_INDEX
     # we search zlocal locally to make sure they get found:
     find $MOONBASE/zlocal -type f -name DETAILS | sed "s:$MOONBASE/::g" | sed 's|/|:|' | sed 's:/DETAILS::g' | awk -F: '{print $2":"$1}' >> $TMP_INDEX
   else
     # this *really* is the fastest way to do it, no guarantees, we
     # do have to make sure MOONBASE is coherent and tidy though
     debug_msg "Regenerating \$MODULE_INDEX manually..."
-    echo MOONBASE_MD5:$(set_moonbase_md5) > $TMP_INDEX
-    find $MOONBASE -type f -name DETAILS | sed "s:$MOONBASE/::g" | sed 's|/|:|' | sed 's:/DETAILS::g' | awk -F: '{print $2":"$1}' >> $TMP_INDEX
+    find $MOONBASE -type f -name DETAILS | sed "s:$MOONBASE/::g" | sed 's|/|:|' | sed 's:/DETAILS::g' | awk -F: '{print $2":"$1}' > $TMP_INDEX
   fi
   
   # this should be safe enough:

Index: moonbase.lunar
===================================================================
RCS file: /var/cvs/lunar/theedge/var/lib/lunar/functions/moonbase.lunar,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- moonbase.lunar	19 May 2004 10:04:17 -0000	1.17
+++ moonbase.lunar	29 Oct 2004 14:17:52 -0000	1.18
@@ -88,28 +88,3 @@
 }
 
 
-# function : set_moonbase_md5
-# usage    : set_moonbase_md5
-# purpose  : creates the md5 value of overall moonbase
-set_moonbase_md5() {
-  debug_msg "set_moonbase_md5 ($@)"
-  MOONBASE_MD5=$(echo $MOONBASE/*/* | md5sum | cut -d "-" -f 1-1)
-  echo $MOONBASE_MD5
-}
-
-
-# function : get_moonbase_md5
-# usage    : get_moonbase_md5
-# purpose  : graps the MOONBASE_MD5 line from the $MODULE_INDEX
-get_moonbase_md5() {
-  debug_msg "get_moonbase_md5 ($@)"
-  MOONBASE_MD5=$(grep ^MOONBASE_MD5: $MODULE_INDEX | tail -1 2>/dev/null | \
-                cut -d : -f 2-2)
-  if [ -z "$MOONBASE_MD5" ] ; then
-    MOONBASE_MD5="0"
-  fi
-  echo "$MOONBASE_MD5"
-}
-
-
-

Index: updatelog.lunar
===================================================================
RCS file: /var/cvs/lunar/theedge/var/lib/lunar/functions/updatelog.lunar,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- updatelog.lunar	21 May 2004 10:27:13 -0000	1.14
+++ updatelog.lunar	29 Oct 2004 14:17:52 -0000	1.15
@@ -67,7 +67,7 @@
   MODULE_CHANGES=$(temp_create "module-changes")
 
   if [ -e "$MODULE_INDEX" ] && [ -e "$TMP_MODULE_INDEX" ]; then
-    diff -yI MOONBASE_MD5 $MODULE_INDEX $TMP_MODULE_INDEX | sort > $MODULE_CHANGES
+    diff -y $MODULE_INDEX $TMP_MODULE_INDEX | sort > $MODULE_CHANGES
 
     NEW_MODULES=$(grep '<' $MODULE_CHANGES | wc -l)
     DEL_MODULES=$(grep '>' $MODULE_CHANGES | wc -l)



More information about the Lunar-commits mailing list