Salome HOME
IMP: Verima / New Plugin: Added a plugin for meshers quality testing (work done at...
[modules/smesh.git] / src / Tools / Verima / Base / versions.py
diff --git a/src/Tools/Verima/Base/versions.py b/src/Tools/Verima/Base/versions.py
new file mode 100755 (executable)
index 0000000..b5af348
--- /dev/null
@@ -0,0 +1,21 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+import sys
+import os
+import  subprocess
+
+
+def Chercheversion(salomePath):
+    home=os.environ['HOME']
+    commande=os.path.abspath(os.path.join(home,salomePath,'runAppli'))
+    argus="--version"
+    p = subprocess.Popen([commande,argus], stdout=subprocess.PIPE)
+    (output, err) = p.communicate()
+    version=' '.join(output.split())
+    return version
+
+
+if __name__ == "__main__":
+      print Chercheversion("/local00/home/A96028/Appli")
+