<commit_before>def getPathByTemplate(startDir, templateName)
  chdir startDir
  items = Dir.glob(templateName)

  if items.length > 1
    puts "Error: Several items '#{templateName}' are found:"
    items.each do |item|
       puts "    '#{item}'"
    end
    exit 1
  elsif items.length == 0
    puts 'item not found'
    return nil
  end

  findPath = File.absolute_path(items[0])
  chdir File.dirname(__FILE__)
  return findPath
end

def getRhostudioSuitePath
  startInstallDrive = "c:\\"      
  suiteNameTemplate = "MotorolaRhoMobileSuite*" 

  findItem = getPathByTemplate(startInstallDrive, suiteNameTemplate)

  if findItem.nil?
    return nil
  end

  return File.absolute_path(findItem)
end

def killProgram(name)
  begin 
    command = 'taskkill /F /IM ' + name
    `#{command}`
  rescue Exception => e
    puts e.to_s
  end  
end
<commit_msg>rhostudio-test/common/common.rb: Motorola word was removed.<commit_after>def getPathByTemplate(startDir, templateName)
  chdir startDir
  items = Dir.glob(templateName)

  if items.length > 1
    puts "Error: Several items '#{templateName}' are found:"
    items.each do |item|
       puts "    '#{item}'"
    end
    exit 1
  elsif items.length == 0
    puts 'item not found'
    return nil
  end

  findPath = File.absolute_path(items[0])
  chdir File.dirname(__FILE__)
  return findPath
end

def getRhostudioSuitePath
  startInstallDrive = "c:\\"      
  suiteNameTemplate = "RhoMobileSuite*"

  findItem = getPathByTemplate(startInstallDrive, suiteNameTemplate)

  if findItem.nil?
    return nil
  end

  return File.absolute_path(findItem)
end

def killProgram(name)
  begin 
    command = 'taskkill /F /IM ' + name
    `#{command}`
  rescue Exception => e
    puts e.to_s
  end  
end

{'fraction_non_alphanumeric': 0.09085933223864258, 'fraction_numerical': 0.004378762999452655, 'mean_word_length': 2.707910750507099, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, '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': '7197785', 'n_tokens_mistral': 659, 'n_tokens_neox': 598, 'n_words': 154}