From 230e4f33effe36ab286173e77ebfb7c2ca9fdc40 Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Sun, 12 Aug 2012 01:20:30 -0400 Subject: [PATCH] site.addsitedir() instead of sys.path.insert(). --- build.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build.py b/build.py index a9ca0c7..2971feb 100755 --- a/build.py +++ b/build.py @@ -9,6 +9,7 @@ import subprocess page_src = """#! /usr/bin/env python # -*- coding: utf-8 -*- import os +import site import sys os.chdir("..") @@ -17,7 +18,7 @@ if plat.startswith("sunos"): plat = "solaris" elif plat.startswith("linux"): plat = "linux" -sys.path.insert(0, os.path.expanduser("~/.local/" + plat + "/lib/python2.7/site-packages")) +site.addsitedir(os.path.expanduser("~/.local/" + plat + "/lib/python2.7/site-packages")) sys.path.insert(0, ".") from mako.template import Template