Browse Source

Added initial version of localcheck edir-version in python instead of bash

Michael Honkoop 5 months ago
parent
commit
a44f8767d1
1 changed files with 14 additions and 0 deletions
  1. 14 0
      edir-version.py

+ 14 - 0
edir-version.py

@@ -0,0 +1,14 @@
+#!/usr/bin/python
+
+# 
+import subprocess
+
+myexec = "ndsd"
+
+try:
+    output = subprocess.check_output([myexec, "--version"])
+    output_arr = output.split(' ')
+    print("0 \"" +  output_arr[1] + "\" - Binary Version: " + output_arr[2] + ", DS Version: " + output_arr[3])
+
+except subprocess.CalledProcessError as e:
+    exit()