<commit_before><commit_msg>fabric 1.10.1 (new formula)<commit_after>class Fabric < Formula
  homepage "http://www.fabfile.org"
  url "https://github.com/fabric/fabric/archive/1.10.1.tar.gz"
  sha1 "8ce104f6a66ed62e1fe057a6a9e6da0f02eb464a"

  head "https://github.com/fabric/fabric.git"

  depends_on :python if MacOS.version <= :snow_leopard

  resource "paramiko" do
    url "https://pypi.python.org/packages/source/p/paramiko/paramiko-1.15.2.tar.gz"
    sha1 "754ffa47fd6f78b93fc56437cf14a79bef094f0f"
  end

  resource "pycrypto" do
    url "https://pypi.python.org/packages/source/p/pycrypto/pycrypto-2.6.1.tar.gz"
    sha1 "aeda3ed41caf1766409d4efc689b9ca30ad6aeb2"
  end

  resource "ecdsa" do
    url "https://pypi.python.org/packages/source/e/ecdsa/ecdsa-0.11.tar.gz"
    sha1 "f732f8cdb064bbe47aa830cc2654688da95b78f0"
  end

  def install
    ENV.prepend_create_path "PYTHONPATH", libexec + "lib/python2.7/site-packages"
    ENV.prepend_create_path "PYTHONPATH", prefix + "lib/python2.7/site-packages"

    res = %w[ecdsa pycrypto paramiko]
    install_args = "setup.py", "install", "--prefix=#{libexec}"
    res.each do |r|
      resource(r).stage { system "python", *install_args }
    end

    system "python", "setup.py", "install", "--prefix=#{libexec}"

    (bin/"fab").write_env_script libexec/"bin/fab", :PYTHONPATH => ENV["PYTHONPATH"]
  end

  test do
    (testpath/"fabfile.py").write <<-EOS.undent
    def hello():
        print("Hello world!")
    EOS
    assert_equal "Hello world!\n\nDone.\n", `#{bin}/fab hello`
  end
end
{'fraction_non_alphanumeric': 0.15051679586563307, 'fraction_numerical': 0.07364341085271318, 'mean_word_length': 3.7370030581039755, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 4, 'https://': 5, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5183983', 'n_tokens_mistral': 688, 'n_tokens_neox': 616, 'n_words': 95}