require 'formula' # Include a private copy of this Python app # so we don't have to worry about clashing dependencies. class Pygments '06ab9ecebd713a1a6ae695b190a775ca6dfeb7b2' homepage 'http://rtomayko.github.com/shocco/' depends_on 'markdown' def install Pygments.new.brew { libexec.install ['pygmentize','pygments'] } # Brew into libexec, along with Pygments system "./configure", "PYGMENTIZE=#{libexec}/pygmentize", "--prefix=#{libexec}" system "make" libexec.install "shocco" # Link the script into bin bin.mkpath ln_s libexec+"shocco", bin end def caveats <<-EOS.undent You may also want to install browser: brew install browser shocco `which shocco` | browser EOS end end