diff --git a/bin/steps/pylibmc b/bin/steps/pylibmc
index fa7c45f48ef64223a345c1c99b4f219dfbc3a90d..4f0c2331a37ae10df98d9ab7ef880990ce9bfd66 100755
--- a/bin/steps/pylibmc
+++ b/bin/steps/pylibmc
@@ -16,7 +16,7 @@ VENDORED_MEMCACHED="http://cl.ly/0a191R3K160t1w1P0N25/vendor-libmemcached.tar.gz
 source $BIN_DIR/utils
 
 # If pylibmc exists within requirements, use vendored libmemcached.
-if (grep -Fiq "pylibmc" requirements.txt) then
+if (grep -Eiq "^\s*pylibmc" requirements.txt) then
   echo "-----> Noticed pylibmc. Bootstrapping libmemcached."
   cd .heroku