summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/dotbot10
1 files changed, 10 insertions, 0 deletions
diff --git a/bin/dotbot b/bin/dotbot
index 2c89bb0..09e2d0e 100755
--- a/bin/dotbot
+++ b/bin/dotbot
@@ -5,6 +5,16 @@ import sys, os
PROJECT_ROOT_DIRECTORY = os.path.dirname(
os.path.dirname(os.path.realpath(__file__)))
+def inject(lib_path):
+ path = os.path.join(PROJECT_ROOT_DIRECTORY, 'lib', lib_path)
+ sys.path.insert(0, path)
+
+# version dependent libraries
+if sys.version_info.major >= 3:
+ inject('pyyaml/lib3')
+else:
+ inject('pyyaml/lib')
+
if os.path.exists(os.path.join(PROJECT_ROOT_DIRECTORY, 'dotbot')):
if PROJECT_ROOT_DIRECTORY not in sys.path:
sys.path.insert(0, PROJECT_ROOT_DIRECTORY)