def __listDirectory(path):
allFiles = []
for root, dirs, files in os.walk(path):
- configFileNames = glob.glob(os.path.join(root,'*.cfg')) + glob.glob(os.path.join(root,'*.sh'))
- allFiles += configFileNames
+ cfgFiles = glob.glob(os.path.join(root,'*.cfg'))
+ allFiles += cfgFiles
+
+ shFiles = glob.glob(os.path.join(root,'*.sh'))
+ for f in shFiles:
+ no_ext = os.path.splitext(f)[0]
+ if not os.path.isfile(no_ext+".cfg"):
+ allFiles.append(f)
+
return allFiles
#
if not os.path.isfile(elt) and not os.path.isfile(elt+".py"):
eltInSearchPath = __getScriptPath(elt, searchPathList)
if eltInSearchPath is None or (not os.path.isfile(eltInSearchPath) and not os.path.isfile(eltInSearchPath+".py")):
- raise SalomeContextException("Script not found: %s"%elt)
+ if elt[-3:] == ".py":
+ raise SalomeContextException("Script not found: %s"%elt)
+ continue
elt = eltInSearchPath
if elt[-4:] != ".hdf":
# an exception is raised if check fails. It allows users for choosing a specific folder.
# Else the function sets OMNIORB_USER_PATH this way:
# - If APPLI environment variable is set, OMNIORB_USER_PATH is set to ${APPLI}/USERS.
-# The function does not check USERS folder existence or wrute access. This folder
-# must exist ; this is the case if SALOME virtual application has been create using
+# The function does not check USERS folder existence or write access. This folder
+# must exist ; this is the case if SALOME virtual application has been created using
# appli_gen.py script.
# - Else OMNIORB_USER_PATH is set to user home directory.
def setOmniOrbUserPath():