Module: nagvis
Branch: master
Commit: 547ccbe9fb292d1c49467d2f5d28e14f496350a6
URL:    
http://nagvis.git.sourceforge.net/git/gitweb.cgi?p=nagvis/nagvis;a=commit;h=547ccbe9fb292d1c49467d2f5d28e14f496350a6

Author: LaMi <[email protected]>
Date:   Wed Feb 17 00:17:25 2010 +0100

Added code to remove deprecated options from main and map configuration files

---

 docs/en_US/map_config_format_description.html |    2 +-
 install.sh                                    |   68 ++++++++++++++++++++----
 2 files changed, 57 insertions(+), 13 deletions(-)

diff --git a/docs/en_US/map_config_format_description.html 
b/docs/en_US/map_config_format_description.html
index 845bd01..e4c4dfa 100644
--- a/docs/en_US/map_config_format_description.html
+++ b/docs/en_US/map_config_format_description.html
@@ -224,7 +224,7 @@
                <td> hover_template </td><td> inherited (<a 
href="#global">global</a>) </td><td> <a href="hover_templates.html">Hover 
template</a> for this object </td>
                </tr>
                <tr>
-               <td> hover_timeout </td><td> inherited (<a 
href="nagvis_config_format_description.html">nagvis.ini.php</a>) </td><td> 
Hover menu ajax request timeout in seconds for this object </td>
+               <td> <strike>hover_timeout</strike> </td><td> <strike>inherited 
(<a href="nagvis_config_format_description.html">nagvis.ini.php</a>)</strike> 
</td><td> <strike>Hover menu ajax request timeout in seconds for this 
object</strike> </td>
                </tr>
                <tr>
                <td> hover_url </td><td> </td><td> URL which should be 
displayed in hover menu instead of standard information. There are some macros 
available:<br />
diff --git a/install.sh b/install.sh
index 92918e2..f04da05 100755
--- a/install.sh
+++ b/install.sh
@@ -3,7 +3,7 @@
 #
 # install.sh - Installs/Updates NagVis
 #
-# Copyright (c) 2004-2009 NagVis Project (Contact: [email protected])
+# Copyright (c) 2004-2010 NagVis Project (Contact: [email protected])
 #
 # Development:
 #  Wolfgang Nieder
@@ -30,7 +30,7 @@
 ###############################################################################
 
 # Installer version
-INSTALLER_VERSION="0.2.11"
+INSTALLER_VERSION="0.2.12"
 # Default action
 INSTALLER_ACTION="install"
 # Be quiet? (Enable/Disable confirmations)
@@ -1161,22 +1161,66 @@ text
 
 # Do some update tasks (Changing options, notify about deprecated options)
 if [ "$INSTALLER_ACTION" = "update" -a "$NAGVIS_VER_OLD" != "UNKNOWN" ]; then
-       line "Handling changed/removed options..." "+"
-       if [ "x`echo $NAGVIS_VER_OLD | grep '1.3'`" != "x" ]; then
-               text "| Update from 1.3.x" "|"
+       line 
+       text "| Handling changed/removed options" "|"
+       line
+       
+       #line "Removing allowedforconfig option from main config..."
+       DONE=`log "Removing allowedforconfig option from main config..." done`
+       sed -i '/^allowedforconfig=/d' $NAGVIS_PATH/etc/nagvis.ini.php
+       chk_rc "| Error" "$DONE"
+       
+       DONE=`log "Removing usegdlibs option from main config..." done`
+       sed -i '/^usegdlibs=/d' $NAGVIS_PATH/etc/nagvis.ini.php
+       chk_rc "| Error" "$DONE"
+       
+       DONE=`log "Removing displayheader option from main config..." done`
+       sed -i '/^displayheader=/d' $NAGVIS_PATH/etc/nagvis.ini.php
+       chk_rc "| Error" "$DONE"
+       
+       DONE=`log "Removing hovertimeout option from main config..." done`
+       sed -i '/^hovertimeout=/d' $NAGVIS_PATH/etc/nagvis.ini.php
+       chk_rc "| Error" "$DONE"
+       
+       DONE=`log "Removing allowed_for_config option from map configs..." done`
+       sed -i '/^allowed_for_config=/d' $NAGVIS_PATH/etc/maps/*.cfg
+       chk_rc "| Error" "$DONE"
+       
+       DONE=`log "Removing allowed_user from map configs..." done`
+       sed -i '/^allowed_user=/d' $NAGVIS_PATH/etc/maps/*.cfg
+       chk_rc "| Error" "$DONE"
+
+       DONE=`log "Removing allowed_for_config from automap configs..." done`
+       sed -i '/^allowed_for_config=/d' $NAGVIS_PATH/etc/automaps/*.cfg
+       chk_rc "| Error" "$DONE"
+
+       DONE=`log "Removing allowed_user from automap configs..." done`
+       sed -i '/^allowed_user=/d' $NAGVIS_PATH/etc/automaps/*.cfg
+       chk_rc "| Error" "$DONE"
+
+       DONE=`log "Removing hover_timeout from map configs..." done`
+       sed -i '/^hover_timeout=/d' $NAGVIS_PATH/etc/maps/*.cfg
+       chk_rc "| Error" "$DONE"
+
+       DONE=`log "Removing usegdlibs from map configs..." done`
+       sed -i '/^usegdlibs=/d' $NAGVIS_PATH/etc/maps/*.cfg
+       chk_rc "| Error" "$DONE"
+
+       line
+       
+       if [ $NAGVIS_TAG_OLD -ge 01030000 ] && [ $NAGVIS_TAG_OLD -lt 01050000 
]; then
+               text "| Version specific changes from 1.3.x or 1.4.x " "|"
                text
                line "Applying changes to main configuration file..."
-               text "| oops, sorry, not implemented yet" "|"
+               text "| oops, no changes yet" "|"
                chk_rc "| Error" "| done"
                line "Applying changes to map configuration files..."
-               text "| oops, sorry, not implemented yet" "|"
+               text "| oops, no changes yet" "|"
                chk_rc "| Error" "| done"
-       else
-               text "| Update from unhandled version $NAGVIS_VER_OLD" "|"
-               text
-               text "| HINT: Please check the changelog or the documentation 
for changes which" "|"
-               text "|       affect your configuration files" "|"
        fi
+       
+       text "| HINT: Please check the changelog or the documentation for 
changes which" "|"
+       text "|       affect your configuration files" "|"
 fi
 text
 


------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins

Reply via email to