]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
trim quoted paths
authorCédric Aguerre <cedric.aguerre@edf.fr>
Fri, 11 Apr 2014 11:29:58 +0000 (13:29 +0200)
committerCédric Aguerre <cedric.aguerre@edf.fr>
Fri, 11 Apr 2014 11:29:58 +0000 (13:29 +0200)
bin/parseConfigFile.py

index d8722a6cfb8bab8953f518b56b96d802ef8135e6..7590fbaf3e1c780b15d86b9bd8125a71f8cbe615 100644 (file)
@@ -103,6 +103,12 @@ class MultiOptSafeConfigParser(ConfigParser.SafeConfigParser):
                 if pos != -1 and optval[pos-1].isspace():
                   optval = optval[:pos]
               optval = optval.strip()
+              # ADD THESE LINES
+              splittedComments = optval.split('#')
+              optval = splittedComments[0].strip().strip("'").strip('"')
+              #if len(splittedComments) > 1:
+              #  optval += " #" + " ".join(splittedComments[1:])
+              # END OF ADD
               # allow empty values
               if optval == '""':
                 optval = ''