]> Creatis software - creaToolsTools.git/blobdiff - Linux/scripts/LocalFunctions.sh
#2493 creaToolsTools Feature New Normal - Prepare and Install binary CreaTools...
[creaToolsTools.git] / Linux / scripts / LocalFunctions.sh
index 8d61359c787e51e9312fb08b7b81097d28331aac..c84fca48db57af7d048171f090e27f80b3eff32a 100644 (file)
@@ -72,10 +72,11 @@ function getDistrib {
 
 ###########################################
 function getDistribVersion {
-    local OS=`uname`
+    local DISTRIB=`getDistrib`
 
-      if [ "$OS" == Darwin ] ; then OSVesion=VOID_Darwin_EED;
-    elif [ "$OS" == Linux  ] ; then OSVersion=`awk 'NR==1{print $3}' /etc/issue`
+      if [ "$DISTRIB" == MacOS ] ; then OSVesion=VOID_Darwin_EED;
+    elif [ "$DISTRIB" == Fedora  ] ; then OSVersion=`awk 'NR==1{print $3}' /etc/issue`
+    elif [ "$DISTRIB" == Ubuntu  ] ; then OSVersion=`awk 'NR==1{print $2}' /etc/issue`
     else OSVersion="VOID_EED"
     fi
     echo $OSVersion