From 1a1cedfc2153f12828f92ebc76997a172fec9451 Mon Sep 17 00:00:00 2001
From: Kenneth Reitz <me@kennethreitz.org>
Date: Mon, 19 Dec 2016 16:37:03 -0500
Subject: [PATCH] symlink eggs

---
 bin/compile | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/bin/compile b/bin/compile
index 0ef5bc66..82a05edd 100755
--- a/bin/compile
+++ b/bin/compile
@@ -202,8 +202,11 @@ set-default-env PYTHONPATH /app/
 # Install sane-default script for $WEB_CONCURRENCY and $FORWARDED_ALLOW_IPS.
 cp $ROOT_DIR/vendor/python.gunicorn.sh $GUNICORN_PROFILE_PATH
 
-# Deep copy the directory for -e pip installations
-deep-cp /app/.heroku/src $BUILD_DIR/.heroku/src
+# Symlink the directory for -e pip installations
+if [[ $BUILD_DIR != '/app' ]]; then
+  mv /app/.heroku/src $BUILD_DIR/.heroku
+  ln -s /app/.heroku/src $BUILD_DIR/.heroku/src
+fi
 
 # Experimental post_compile hook.
 bpwatch start post_compile
-- 
GitLab