[Lunar-commits] r18946 - lunar/trunk/var/lib/lunar/functions
Auke Kok
sofar at lunar-linux.org
Wed Mar 1 00:18:18 UTC 2006
Author: sofar
Date: 2006-03-01 00:18:14 +0000 (Wed, 01 Mar 2006)
New Revision: 18946
Modified:
lunar/trunk/var/lib/lunar/functions/optimize.lunar
Log:
Always set $PLATFORM and $BUILD according to the system (this is done BEFORE local config - so you can override them with `lunar set BUILD` etc.). Also allow the menu to be empty (i.e. no plugins installed).
Modified: lunar/trunk/var/lib/lunar/functions/optimize.lunar
===================================================================
--- lunar/trunk/var/lib/lunar/functions/optimize.lunar 2006-02-28 22:45:20 UTC (rev 18945)
+++ lunar/trunk/var/lib/lunar/functions/optimize.lunar 2006-03-01 00:18:14 UTC (rev 18946)
@@ -14,11 +14,27 @@
{(
export IFS=$'\t\n'
while true; do
+ if [ -z "$(plugin_call OPTIMIZE_MENU)" ]; then
+ $DIALOG --msgbox "There are no configurable compontents. Please update your moonbase!" 6 60
+ return
+ fi
PLUGIN=`$DIALOG --cancel-label "Close" --menu "Select a component for which to configure optimizations" 0 0 0 $(plugin_call OPTIMIZE_MENU)`
if [ $? != 0 ]; then
return
fi
plugin_call OPTIMIZE_MENU $PLUGIN
- done
+ done
)}
+
+
+# because we pretty much need to know our $BUILD string
+# everywhere this code is separate and guides all other
+# parts of lunar where related things are done. Here we
+# autodetect the most important part but leave it open
+# to the user to override it
+
+# PLATFORM - translated uname -m / arch
+PLATFORM=$(uname -m | sed 's/i[3456]86/x86/')
+BUILD=$(uname -m )-pc-linux-gnu
+
More information about the Lunar-commits
mailing list