Index: trunk/libIGCM/libIGCM_comp/libIGCM_comp.ksh
===================================================================
--- trunk/libIGCM/libIGCM_comp/libIGCM_comp.ksh	(revision 1155)
+++ trunk/libIGCM/libIGCM_comp/libIGCM_comp.ksh	(revision 1156)
@@ -1035,21 +1035,21 @@
   # Check if AUTO is set in the filein on the same line as the key variable
   if [ $( grep -w $key $filein | grep -v "\#" | grep AUTO | wc -l ) = 1 ] ; then
-      # Modification will be done for all cases
+    # Modification will be done for all cases
+    modify=yes
+  else
+    # The variable was not set to AUTO
+    if [ $type = blocker ] ; then
+      # Exit because this is a blocker call
+      IGCM_debug_Exit "IGCM_comp_modifyDefFile : The variable $key cannot be modified. It should be set to AUTO."
+      return
+    elif [ $type = nonblocker ] ; then
+      # Do nothing. Suppose that the user did set the variable correct
+      IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: $key is set by the user. Nothing done."
+      modify=no
+    elif [ $type = force ] ; then
+      # Force modification
+      IGCM_debug_Print 1 "IGCM_comp_modifyDefFile : Variabl=$key was not set to AUTO. Modification will be forced."
       modify=yes
-  else
-      # The variable was not set to AUTO
-      if [ $type = blocker ] ; then
-          # Exit because this is a blocker call
-          IGCM_debug_Exit "IGCM_comp_modifyDefFile : The variable $key cannot be modified. It should be set to AUTO."
-          return
-       elif [ $type = nonblocker ] ; then
-          # Do nothing. Suppose that the user did set the variable correct
-          IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: $key is set by the user. Nothing done."
-          modify=no
-       elif [ $type = force ] ; then
-          # Force modification
-          IGCM_debug_Print 1 "IGCM_comp_modifyDefFile : Variabl=$key was not set to AUTO. Modification will be forced."
-          modify=yes
-      fi
+    fi
   fi
 
@@ -1057,23 +1057,23 @@
   if [ $modify = yes ] ; then
 
-      # For option DEFAULT, read default value from file.
-      if [ X"$value" = XDEFAULT ] || [ X"$value" = X ] ; then
-        # Case to set DEFAULT value
-        # Read default value from filein
-        value=$( grep $key $filein | grep -v "\#" | awk  -F"DEFAULT *=" '{print $2}')
-
-        if [ X"$value" = X ] ; then
-          IGCM_debug_Exit "IGCM_comp_modifyDefFile : The variable $key needs a DEFAULT value in $filein."
-          IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: The syntax in $filein should be:"
-          IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: $key=_AUTO_:DEFAULT=def_value"
-          IGCM_debug_PopStack "IGCM_comp_modifyDefFile"
-          return
-        fi
+    # For option DEFAULT, read default value from file.
+    if [ X"$value" = XDEFAULT ] || [ X"$value" = X ] ; then
+      # Case to set DEFAULT value
+      # Read default value from filein
+      value=$( grep $key $filein | grep -v "\#" | awk  -F"DEFAULT *=" '{print $2}')
+
+      if [ X"$value" = X ] ; then
+        IGCM_debug_Exit "IGCM_comp_modifyDefFile : The variable $key needs a DEFAULT value in $filein."
+        IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: The syntax in $filein should be:"
+        IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: $key=_AUTO_:DEFAULT=def_value"
+        IGCM_debug_PopStack "IGCM_comp_modifyDefFile"
+        return
       fi
-
-      # Now change key in filein
-      sed -e "s/^${key}\ *=.*/${key}= ${value}/" $filein > $filein.tmp
-      IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: In $filein set $key=$value"
-      \mv $filein.tmp $filein
+    fi
+
+    # Now change key in filein
+    sed -e "s/^${key}\ *=.*/${key}= ${value}/" $filein > $filein.tmp
+    IGCM_debug_Print 1 "IGCM_comp_modifyDefFile: In $filein set $key=$value"
+    \mv $filein.tmp $filein
   fi
   IGCM_debug_PopStack "IGCM_comp_modifyDefFile"
@@ -1140,30 +1140,30 @@
   # Verify the existance of the pattern
   if [ X"$pattern" = X ] ; then
-      # Variable key is not set in filein, stop.
-      IGCM_debug_Exit "IGCM_comp_modifyNamelist : Variable $key is not set in correct file. It should be set in $filein."
+    # Variable key is not set in filein, stop.
+    IGCM_debug_Exit "IGCM_comp_modifyNamelist : Variable $key is not set in correct file. It should be set in $filein."
+    IGCM_debug_PopStack "IGCM_comp_modifyNamelist"
+    return
+  fi
+
+  # Check if the variable is set to AUTO in the filein
+  if [ $( echo $pattern | grep AUTO | wc -l ) = 1 ] ; then
+    # Modification will be done for all cases
+    modify=yes
+  else
+    # The variable was not set to AUTO
+    if [ $type = blocker ] ; then
+      # Exit because this is a blocker call
+      IGCM_debug_Exit "IGCM_comp_modifyNamelist : The variable $key cannot be modified. It should be set to AUTO."
       IGCM_debug_PopStack "IGCM_comp_modifyNamelist"
       return
-  fi
-
-  # Check if the variable is set to AUTO in the filein
-  if [ $( echo $pattern | grep AUTO | wc -l ) = 1 ] ; then
-      # Modification will be done for all cases
+    elif [ $type = nonblocker ] ; then
+      # Do nothing. Suppose that the user did set the variable correct
+      IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: $key is set by the user. Nothing done."
+      modify=no
+    elif [ $type = force ] ; then
+      # Force modification
+      IGCM_debug_Print 1 "IGCM_comp_modifyNamelist : Variabl=$key was not set to AUTO. Modification will be forced."
       modify=yes
-  else
-      # The variable was not set to AUTO
-      if [ $type = blocker ] ; then
-          # Exit because this is a blocker call
-          IGCM_debug_Exit "IGCM_comp_modifyNamelist : The variable $key cannot be modified. It should be set to AUTO."
-          IGCM_debug_PopStack "IGCM_comp_modifyNamelist"
-          return
-       elif [ $type = nonblocker ] ; then
-          # Do nothing. Suppose that the user did set the variable correct
-          IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: $key is set by the user. Nothing done."
-          modify=no
-       elif [ $type = force ] ; then
-          # Force modification
-          IGCM_debug_Print 1 "IGCM_comp_modifyNamelist : Variabl=$key was not set to AUTO. Modification will be forced."
-          modify=yes
-      fi
+    fi
   fi
 
@@ -1171,23 +1171,23 @@
   if [ $modify = yes ] ; then
 
-      # For option DEFAULT, read default value from file.
-      if [ X"$value" = XDEFAULT ] || [ X"$value" = X ] ; then
-        # Case to set DEFAULT value
-        # Read default value from filein
-        value=$( echo $pattern | awk  -F"DEFAULT *=" '{print $2}')
-
-        if [ X"$value" = X ] ; then
-          IGCM_debug_Exit "IGCM_comp_modifyNamelist : The variable $key needs a DEFAULT value in $filein."
-          IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: The syntax in $filein should be:"
-          IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: $key=_AUTO_:DEFAULT=def_value"
-          IGCM_debug_PopStack "IGCM_comp_modifyNamelist"
-          return
-        fi
+    # For option DEFAULT, read default value from file.
+    if [ X"$value" = XDEFAULT ] || [ X"$value" = X ] ; then
+      # Case to set DEFAULT value
+      # Read default value from filein
+      value=$( echo $pattern | awk  -F"DEFAULT *=" '{print $2}')
+
+      if [ X"$value" = X ] ; then
+        IGCM_debug_Exit "IGCM_comp_modifyNamelist : The variable $key needs a DEFAULT value in $filein."
+        IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: The syntax in $filein should be:"
+        IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: $key=_AUTO_:DEFAULT=def_value"
+        IGCM_debug_PopStack "IGCM_comp_modifyNamelist"
+        return
       fi
-
-      # Now change key in filein
-      sed -e "s/${pattern}/       $key=${value}/" $filein > $filein.tmp
-      IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: In $filein set $key=$value"
-      \mv $filein.tmp $filein
+    fi
+
+    # Now change key in filein
+    sed -e "s/${pattern}/       $key=${value}/" $filein > $filein.tmp
+    IGCM_debug_Print 1 "IGCM_comp_modifyNamelist: In $filein set $key=$value"
+    \mv $filein.tmp $filein
   fi
   IGCM_debug_PopStack "IGCM_comp_modifyNamelist"
@@ -1282,14 +1282,14 @@
       sed -e "s/\(<[^\"]*\"${keyid}\".*>\)\([^<]*\)\(<[^>]*\)/\1${value}\3/" $filein > $filein.tmp
     else
-          # Check if keyattrib is set on the same line as keyid
-        if [  $( grep -w $keyid $filein | grep $keyattrib | wc -l ) = 1 ] ; then
-            # Case to modify the attribute value
-            IGCM_debug_Print 1 "Now modify ${filein} for id=${keyid} by setting attribute to ${keyattrib}=${value}"
-            sed -e "/id=\"${keyid}\"/s/\(${keyattrib}=\"\)[^\"]*\(\"\)/\1${value}\2/" $filein > $filein.tmp
-        else
-            # Case to add the attribute and its value
-             IGCM_debug_Print 1 "Now add in ${filein} for id=${keyid} the attribute ${keyattrib} to the value ${value}"
-             sed -e "/id=\"${keyid}\"/s/\/>/ ${keyattrib}=\"${value}\"\/>/" $filein > $filein.tmp
-        fi
+      # Check if keyattrib is set on the same line as keyid
+      if [  $( grep -w $keyid $filein | grep $keyattrib | wc -l ) = 1 ] ; then
+        # Case to modify the attribute value
+        IGCM_debug_Print 1 "Now modify ${filein} for id=${keyid} by setting attribute to ${keyattrib}=${value}"
+        sed -e "/id=\"${keyid}\"/s/\(${keyattrib}=\"\)[^\"]*\(\"\)/\1${value}\2/" $filein > $filein.tmp
+      else
+        # Case to add the attribute and its value
+        IGCM_debug_Print 1 "Now add in ${filein} for id=${keyid} the attribute ${keyattrib} to the value ${value}"
+        sed -e "/id=\"${keyid}\"/s/\/>/ ${keyattrib}=\"${value}\"\/>/" $filein > $filein.tmp
+      fi
     fi
     \mv $filein.tmp $filein
