// Path: buildSrc/src/main/java/org/jazzcommunity/development/library/DetectOperatingSystem.java
// public class DetectOperatingSystem {
//   public static boolean isWindows() {
//     return OperatingSystem.current().isWindows();
//   }
// 
//   public static boolean isLinux() {
//     return OperatingSystem.current().isLinux();
//   }
// }
// 
// Path: buildSrc/src/main/java/org/jazzcommunity/development/library/file/FileReader.java
// public class FileReader {
//   private static final Logger logger = LoggerFactory.getLogger("FileReader");
// 
//   private FileReader() {}
// 
//   public static Stream<String> raw(File path) {
//     if (!path.exists()) {
//       logger.error("File {} does not exist", path);
//     }
// 
//     CharSource source = Files.asCharSource(path, StandardCharsets.UTF_8);
//     return raw(source);
//   }
// 
//   public static Stream<String> raw(CharSource source) {
//     try {
//       return source.lines();
//     } catch (IOException e) {
//       if (logger.isDebugEnabled()) {
//         e.printStackTrace();
//       }
//       logger.error("Error occurred reading files: {}", e.getMessage());
//       return Stream.empty();
//     }
//   }
// 
//   public static Stream<String> read(File path) {
//     return raw(path).map(String::trim);
//   }
// 
//   public static Stream<String> read(CharSource source) {
//     return raw(source).map(String::trim);
//   }
// }
// 
// Path: buildSrc/src/main/java/org/jazzcommunity/development/library/file/FileResolver.java
// public final class FileResolver {
//   private static final Logger logger = LoggerFactory.getLogger("FileResolver");
// 
//   private FileResolver() {}
// 
//   public static Stream<Path> findInDirectory(Path directory, String endsWith) {
//     try {
//       return Files.find(directory, 1, (p, b) -> p.getFileName().toString().endsWith(endsWith));
//     } catch (IOException e) {
//       if (logger.isDebugEnabled()) {
//         e.printStackTrace();
//       }
//       logger.info(
//           "File ending with '{}' in '{}' not found. Ignoring this entry.", directory, endsWith);
//       return null;
//     }
//   }
// }


import java.io.File;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.stream.Stream;
import org.jazzcommunity.development.library.DetectOperatingSystem;
import org.jazzcommunity.development.library.file.FileReader;
import org.jazzcommunity.development.library.file.FileResolver;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
package org.jazzcommunity.development.library.config.plugin;


class ServiceEntry implements IniEntry {

  private final Logger logger = LoggerFactory.getLogger(this.getClass());
  private final File directory;

  public ServiceEntry(File directory) {
    this.directory = directory;
  }

  @Override
  public String getIniLine() {
    // TODO: duplicated code
    String formatted = directory.getPath();

// Path: buildSrc/src/main/java/org/jazzcommunity/development/library/DetectOperatingSystem.java
// public class DetectOperatingSystem {
//   public static boolean isWindows() {
//     return OperatingSystem.current().isWindows();
//   }
// 
//   public static boolean isLinux() {
//     return OperatingSystem.current().isLinux();
//   }
// }
// 
// Path: buildSrc/src/main/java/org/jazzcommunity/development/library/file/FileReader.java
// public class FileReader {
//   private static final Logger logger = LoggerFactory.getLogger("FileReader");
// 
//   private FileReader() {}
// 
//   public static Stream<String> raw(File path) {
//     if (!path.exists()) {
//       logger.error("File {} does not exist", path);
//     }
// 
//     CharSource source = Files.asCharSource(path, StandardCharsets.UTF_8);
//     return raw(source);
//   }
// 
//   public static Stream<String> raw(CharSource source) {
//     try {
//       return source.lines();
//     } catch (IOException e) {
//       if (logger.isDebugEnabled()) {
//         e.printStackTrace();
//       }
//       logger.error("Error occurred reading files: {}", e.getMessage());
//       return Stream.empty();
//     }
//   }
// 
//   public static Stream<String> read(File path) {
//     return raw(path).map(String::trim);
//   }
// 
//   public static Stream<String> read(CharSource source) {
//     return raw(source).map(String::trim);
//   }
// }
// 
// Path: buildSrc/src/main/java/org/jazzcommunity/development/library/file/FileResolver.java
// public final class FileResolver {
//   private static final Logger logger = LoggerFactory.getLogger("FileResolver");
// 
//   private FileResolver() {}
// 
//   public static Stream<Path> findInDirectory(Path directory, String endsWith) {
//     try {
//       return Files.find(directory, 1, (p, b) -> p.getFileName().toString().endsWith(endsWith));
//     } catch (IOException e) {
//       if (logger.isDebugEnabled()) {
//         e.printStackTrace();
//       }
//       logger.info(
//           "File ending with '{}' in '{}' not found. Ignoring this entry.", directory, endsWith);
//       return null;
//     }
//   }
// }


// Path: buildSrc/src/main/java/org/jazzcommunity/development/library/config/plugin/ServiceEntry.java
import java.io.File;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.stream.Stream;
import org.jazzcommunity.development.library.DetectOperatingSystem;
import org.jazzcommunity.development.library.file.FileReader;
import org.jazzcommunity.development.library.file.FileResolver;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

package org.jazzcommunity.development.library.config.plugin;


class ServiceEntry implements IniEntry {

  private final Logger logger = LoggerFactory.getLogger(this.getClass());
  private final File directory;

  public ServiceEntry(File directory) {
    this.directory = directory;
  }

  @Override
  public String getIniLine() {
    // TODO: duplicated code
    String formatted = directory.getPath();

    if (DetectOperatingSystem.isWindows()) {