[Lunar-commits]
CVS: theedge/var/lib/lunar/functions messages.lunar, 1.17, 1.18
Auke Kok
sofar at lunar-linux.org
Thu Nov 4 09:31:59 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:
messages.lunar
Log Message:
Adding the 'mquery' function wrapper. This will be used later to simplify writing CONFIGURE statements (of course it also will work from BUILD but you shouldn't do that)
Index: messages.lunar
===================================================================
RCS file: /var/cvs/lunar/theedge/var/lib/lunar/functions/messages.lunar,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- messages.lunar 9 Aug 2004 12:11:03 -0000 1.17
+++ messages.lunar 4 Nov 2004 09:31:57 -0000 1.18
@@ -142,6 +142,26 @@
}
+# mquery is a wrapper to autodetect if a certain y/n parameter in a module
+# config is not set yet and handles the case in a single function
+# usage: mqeury USE_LILO "Use lilo instead of grub" ?
+# note : $MODULE must be set properly
+mquery()
+{
+ debug_msg "mquery ($@)"
+ if [ -n "$MODULE" ]; then
+ if [ -z "$(get_module_config $1)" ]; then
+ # it's not set yet... start the asking loop
+ if query "$2" "$3" ; then
+ set_module_config "$1" y
+ else
+ set_module_config "$1" n
+ fi
+ fi
+ fi
+}
+
+
color() {
debug_msg "color ($@)"
case $1 in
More information about the Lunar-commits
mailing list