<commit_before>require "formula"

class Mvnvm < Formula
  homepage "http://mvnvm.org"
  url "https://bitbucket.org/mjensen/mvnvm/get/mvnvm-1.0.2.zip"
  sha1 "53ac240787cc3a3f2743bb57a2e4448587519900"

  head "https://bitbucket.org/mjensen/mvnvm.git"

  depends_on :java => "1.7"

  def install
    bin.install "mvn"
  end

  conflicts_with "maven",
    :because => "also installs a 'mvn' executable"

  test do
    ENV["JAVA_HOME"] = `/usr/libexec/java_home`.chomp
    (testpath/"mvnvm.properties").write <<-EOS.undent
      mvn_version=3.2.5
    EOS
    (testpath/"pom.xml").write <<-EOS.undent
      <?xml version="1.0" encoding="UTF-8"?>
      <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
        <modelVersion>4.0.0</modelVersion><commit_msg>mvnvm 1.0.3<commit_after>class Mvnvm < Formula
  homepage "http://mvnvm.org"
  url "https://bitbucket.org/mjensen/mvnvm/get/mvnvm-1.0.3.zip"
  sha1 "e72f47104ac16575f992be4234ab264579d66444"

  head "https://bitbucket.org/mjensen/mvnvm.git"

  depends_on :java => "1.7+"

  def install
    bin.install "mvn"
  end

  conflicts_with "maven", :because => "also installs a 'mvn' executable"

  test do
    ENV["JAVA_HOME"] = `/usr/libexec/java_home`.chomp
    (testpath/"mvnvm.properties").write <<-EOS.undent
      mvn_version=3.2.5
    EOS
    (testpath/"pom.xml").write <<-EOS.undent
      <?xml version="1.0" encoding="UTF-8"?>
      <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
        <modelVersion>4.0.0</modelVersion>
{'fraction_non_alphanumeric': 0.17630700778642935, 'fraction_numerical': 0.06729699666295884, 'mean_word_length': 3.3985330073349633, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 2, '>': 15, 'https://': 4, 'lorem ipsum': 0, 'www.': 2, 'xml': 8}, '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': '5675606', 'n_tokens_mistral': 811, 'n_tokens_neox': 733, 'n_words': 94}