<commit_before>require 'formula'

class AndroidSdk < Formula
  homepage 'http://developer.android.com/index.html'
  url 'https://dl.google.com/android/android-sdk_r23.0.2-macosx.zip'
  version '23.0.2'
  sha1 '1ef502577ca4403ae81f3d68c1813995cb412354'

  conflicts_with 'android-platform-tools',
    :because => "The Android Platform-Tools need to be installed as part of the SDK."

  resource 'completion' do
    url 'https://raw.githubusercontent.com/CyanogenMod/android_sdk/938c8d70af7d77dfcd1defe415c1e0deaa7d301b/bash_completion/adb.bash'
    sha1 '6dfead9b1350dbe1c16a1c80ed70beedebfa39eb'
  end

  # Version of the android-build-tools the wrapper scripts reference.
  def build_tools_version
    "20.0.0"
  end

  def install
    prefix.install 'tools', 'SDK Readme.txt' => 'README'

    %w[android ddms draw9patch emulator
    emulator-arm emulator-x86 hierarchyviewer lint mksdcard<commit_msg>android-sdk 23.0.2: Fix for Linuxbrew<commit_after>require 'formula'

class AndroidSdk < Formula
  homepage 'http://developer.android.com/index.html'
  version '23.0.2'
  if OS.mac?
      url "https://dl.google.com/android/android-sdk_r23.0.2-macosx.zip"
      sha1 "1ef502577ca4403ae81f3d68c1813995cb412354"
  elsif OS.linux?
      url "https://dl.google.com/android/android-sdk_r23.0.2-linux.tgz"
      sha1 "6b79b05bc876a8126f5ba034602e01306706de75"
  else
      raise "Unknown operating system"
  end

  conflicts_with 'android-platform-tools',
    :because => "The Android Platform-Tools need to be installed as part of the SDK."

  resource 'completion' do
    url 'https://raw.githubusercontent.com/CyanogenMod/android_sdk/938c8d70af7d77dfcd1defe415c1e0deaa7d301b/bash_completion/adb.bash'
    sha1 '6dfead9b1350dbe1c16a1c80ed70beedebfa39eb'
  end

  # Version of the android-build-tools the wrapper scripts reference.
  def build_tools_version
    "20.0.0"
  end

  def install
    prefix.install 'tools', 'SDK Readme.txt' => 'README'

    %w[android ddms draw9patch emulator
    emulator-arm emulator-x86 hierarchyviewer lint mksdcard
{'fraction_non_alphanumeric': 0.097799511002445, 'fraction_numerical': 0.097799511002445, 'mean_word_length': 4.12781954887218, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 5, 'lorem ipsum': 0, 'www.': 0, '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': '1838935', 'n_tokens_mistral': 870, 'n_tokens_neox': 761, 'n_words': 145}