diff --git a/Formula/git-cola.rb b/Formula/git-cola.rb index 73aed27d05..ceeca0eccc 100644 --- a/Formula/git-cola.rb +++ b/Formula/git-cola.rb @@ -19,7 +19,7 @@ class GitCola < Formula end def install - ENV.prepend 'PYTHONPATH', "#{HOMEBREW_PREFIX}/lib/python", ':' + ENV.prepend 'PYTHONPATH', "#{HOMEBREW_PREFIX}/lib/#{which_python}/site-packages", ':' system "make", "prefix=#{prefix}", "install" if ARGV.include? '--build-docs' @@ -30,4 +30,8 @@ class GitCola < Formula "install", "install-html" end end + + def which_python + "python" + `python -c 'import sys;print(sys.version[:3])'`.strip + end end