[Lunar-commits] <lunar> [FIX] Honor platform specific DETAILS file when using 'want version (-w)'

Stefan Wold ratler at lunar-linux.org
Sun Feb 20 15:50:03 CET 2011


commit e4f234bf75c955aa5259d20107a687707f630e7c
Author: Stefan Wold <ratler at lunar-linux.org>
Date:   Sun Feb 20 15:47:40 2011 +0100

    [FIX] Honor platform specific DETAILS file when using 'want version (-w)'
---
 var/lib/lunar/functions/modules.lunar |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/var/lib/lunar/functions/modules.lunar b/var/lib/lunar/functions/modules.lunar
index 64a616b..d8c2831 100644
--- a/var/lib/lunar/functions/modules.lunar
+++ b/var/lib/lunar/functions/modules.lunar
@@ -241,7 +241,11 @@ run_details() {
       run_module_file $1 DETAILS &> /dev/null || return 255
     else
       TMP_DETAILS=$(temp_create "details.version")
-      cat $MOONBASE/$SECTION/$1/DETAILS | sed '/^\s*VERSION=/d' > $TMP_DETAILS
+      if [[ -e "$MOONBASE/$SECTION/$1/DETAILS.$PLATFORM" ]]; then
+        cat $MOONBASE/$SECTION/$1/DETAILS.$PLATFORM | sed '/^\s*VERSION=/d' > $TMP_DETAILS
+      else
+        cat $MOONBASE/$SECTION/$1/DETAILS | sed '/^\s*VERSION=/d' > $TMP_DETAILS
+      fi        
       VERSION="$WANT_VERSION"
       . $TMP_DETAILS &> /dev/null || return 255
       temp_destroy $TMP_DETAILS


More information about the Lunar-commits mailing list