]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
Restore passing single study file as command line argument
authoraguerre <aguerre>
Wed, 28 Aug 2013 16:17:34 +0000 (16:17 +0000)
committeraguerre <aguerre>
Wed, 28 Aug 2013 16:17:34 +0000 (16:17 +0000)
bin/launchConfigureParser.py
bin/salomeLauncherUtils.py

index b1d8aed20bfb221aef9df16f0f13845234319ea0..d89e2d1df708716bdb69e7845adc234b567e0eac 100755 (executable)
@@ -1013,9 +1013,8 @@ def get_env(theAdditionalOptions=[], appname=salomeappname, cfgname=salomecfgnam
       args["ns_port_log_file"] = cmd_opts.ns_port_log_file
 
     # Study files
-    if len(cmd_args) > 0 and not args["study_hdf"]:
-        arg = cmd_args[0] # :NOTE: only look at first element
-        if arg[-4:] == ".hdf":
+    for arg in cmd_args:
+        if arg[-4:] == ".hdf" and not args["study_hdf"]:
             args["study_hdf"] = arg
 
     # Python scripts
index 6e23076ddd7562c14946b0b6cc0b91fe626d2b68..f64e83fcc04224f969376bb52660898f56f3788c 100644 (file)
@@ -82,12 +82,14 @@ def getScriptsAndArgs(args=[]):
       if elt[-3:] == ".py":
         currentScript = os.path.abspath(elt)
       else:
-        currentScript = os.path.abspath(elt+".py")
-      if callPython:
+        currentScript = None
+        if elt[-4:] != ".hdf":
+          currentScript = os.path.abspath(elt+".py")
+      if currentScript and callPython:
         currentKey = "python "+currentScript
         scriptArgs.append({currentKey:[]})
         callPython = False
-      else:
+      elif currentScript:
         if not os.access(currentScript, os.X_OK):
           currentKey = "python "+currentScript
           scriptArgs.append({currentKey:[]})