<commit_before>cask 'ncar-ncl' do
  version '6.5.0'

  if MacOS.version == :sierra
    sha256 'b107934b17085c39053467aa3faa07f00b4e18a89271a0b15eec6768d6ab06fb'
    url "https://www.earthsystemgrid.org/dataset/ncl.#{version.no_dots}.dap/file/ncl_ncarg-#{version}-MacOS_10.12_64bit_gnu710.tar.gz"
  else
    sha256 '18d95acc8a9904c930d61b24348d13603c53a28e7c50c86f28b4354f823dc3df'
    url "https://www.earthsystemgrid.org/dataset/ncl.#{version.no_dots}.dap/file/ncl_ncarg-#{version}-MacOS_10.13_64bit_gnu730.tar.gz"
  end

  appcast 'https://www.ncl.ucar.edu/current_release.shtml'
  name 'NCAR Command Language'
  name 'ncl'
  homepage 'https://www.ncl.ucar.edu/'

  depends_on x11: true
  depends_on formula: 'gcc'
  depends_on macos: '>= :sierra'

  artifact 'include', target: "#{HOMEBREW_PREFIX}/ncl-#{version}/include"
  artifact 'bin', target: "#{HOMEBREW_PREFIX}/ncl-#{version}/bin"
  artifact 'lib', target: "#{HOMEBREW_PREFIX}/ncl-#{version}/lib"

  preflight do
    system_command '/bin/mkdir', args: ['-p', "#{HOMEBREW_PREFIX}/ncl-#{version}"], sudo: true
  end

  uninstall delete: "#{HOMEBREW_PREFIX}/ncl-#{version}"

  caveats <<~EOS
    To use ncar-ncl, you must add the ${NCARG_ROOT}/bin directory
    to your PATH environment variable.

    For bash shell, add these lines to ~/.bash_profile:
<commit_msg>ncar-ncl: fix RuboCop style.<commit_after>cask "ncar-ncl" do
  version "6.5.0"

  if MacOS.version == :sierra
    sha256 "b107934b17085c39053467aa3faa07f00b4e18a89271a0b15eec6768d6ab06fb"
    url "https://www.earthsystemgrid.org/dataset/ncl.#{version.no_dots}.dap/file/ncl_ncarg-#{version}-MacOS_10.12_64bit_gnu710.tar.gz"
  else
    sha256 "18d95acc8a9904c930d61b24348d13603c53a28e7c50c86f28b4354f823dc3df"
    url "https://www.earthsystemgrid.org/dataset/ncl.#{version.no_dots}.dap/file/ncl_ncarg-#{version}-MacOS_10.13_64bit_gnu730.tar.gz"
  end

  appcast "https://www.ncl.ucar.edu/current_release.shtml"
  name "NCAR Command Language"
  name "ncl"
  homepage "https://www.ncl.ucar.edu/"

  depends_on x11: true
  depends_on formula: "gcc"
  depends_on macos: ">= :sierra"

  artifact "include", target: "#{HOMEBREW_PREFIX}/ncl-#{version}/include"
  artifact "bin", target: "#{HOMEBREW_PREFIX}/ncl-#{version}/bin"
  artifact "lib", target: "#{HOMEBREW_PREFIX}/ncl-#{version}/lib"

  preflight do
    system_command "/bin/mkdir", args: ["-p", "#{HOMEBREW_PREFIX}/ncl-#{version}"], sudo: true
  end

  uninstall delete: "#{HOMEBREW_PREFIX}/ncl-#{version}"

  caveats <<~EOS
    To use ncar-ncl, you must add the ${NCARG_ROOT}/bin directory
    to your PATH environment variable.

    For bash shell, add these lines to ~/.bash_profile:

{'fraction_non_alphanumeric': 0.14844043592634348, 'fraction_numerical': 0.08568207440811725, 'mean_word_length': 4.616033755274262, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 8, 'lorem ipsum': 0, 'www.': 8, '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': '5676665', 'n_tokens_mistral': 1225, 'n_tokens_neox': 1092, 'n_words': 175}