<commit_before>package gitbucket.monitoring.services.operatingsystem

import scala.sys.process._
import gitbucket.monitoring.utils.Message

object OperatingSystem {
  sealed abstract class OSType
  case object Linux extends OSType
  case object Windows extends OSType
  case object Mac extends OSType
  case object Other extends OSType

  val osArch = System.getProperty("os.arch")
  val osName = System.getProperty("os.name")
  val osType: OSType = {
    if (osName.toLowerCase.contains("linux")) {
      Linux
    } else if (osName.toLowerCase.contains("windows")) {
      Windows
    } else if (osName.toLowerCase.contains("mac")) {
      Mac
    } else {
      Other
    }
  }

  val osVersion:String = osType match {
    case Windows => {<commit_msg>Refactoring if-else block<commit_after>package gitbucket.monitoring.services.operatingsystem

import scala.sys.process._
import gitbucket.monitoring.utils.Message

object OperatingSystem {
  sealed abstract class OSType
  case object Linux extends OSType
  case object Windows extends OSType
  case object Mac extends OSType
  case object Other extends OSType

  val osArch = System.getProperty("os.arch")
  val osName = System.getProperty("os.name")

  val osType: OSType =
    if (osName.toLowerCase.contains("linux")) Linux
    else if (osName.toLowerCase.contains("windows")) Windows
    else if (osName.toLowerCase.contains("mac")) Mac
    else Other

  val osVersion:String = osType match {
    case Windows => {
{'fraction_non_alphanumeric': 0.08757637474541752, 'fraction_numerical': 0.0, 'mean_word_length': 3.8970099667774085, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '3876485', 'n_tokens_mistral': 428, 'n_tokens_neox': 438, 'n_words': 122}