Add a wrapper for using the tool without installation via setuptools
[kconfig-hardened-check.git] / bin / kconfig-hardened-check
diff --git a/bin/kconfig-hardened-check b/bin/kconfig-hardened-check
new file mode 100755 (executable)
index 0000000..beab71d
--- /dev/null
@@ -0,0 +1,16 @@
+#!/usr/bin/python3
+
+# For using the tool without installation via setuptools
+
+import os
+import sys
+import inspect
+
+current_dir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
+parent_dir = os.path.dirname(current_dir)
+sys.path.insert(0, parent_dir)
+
+import kconfig_hardened_check
+
+if __name__ == "__main__":
+    kconfig_hardened_check.main()