in src/main/java/org/apache/tomee/website/AddBacktickToAnnotations.java [51:75]
public static void process(final File destReadme) {
try {
final List<String> completed = new ArrayList<>();
for (String line : IO.slurp(destReadme).split("\n")) {
if (line == null) { return; }
if (line.equals("----")) {
if (!isCodeBlock.get()) {
isCodeBlock.set(true);
} else {
isCodeBlock.set(false);
}
completed.add(line);
} else if (!isCodeBlock.get()) {
completed.add(replace(line));
} else {
completed.add(line);
}
}
// Update the destination readme file
IO.copy(IO.read(Join.join("\n", completed) + "\n"), destReadme);
} catch (IOException e) {
throw new RuntimeException(e);
}
}