feature/Add glossary items via markdown files 3

This commit is contained in:
Marko Milić 2023-01-25 14:00:42 +01:00
parent 39e0ba731d
commit a2aecc3af3
3 changed files with 4 additions and 4 deletions

View File

@ -58,7 +58,7 @@ To compile and run jetty, install Maven 3, create your configuration in obp-api/
mvn install -pl .,obp-commons && mvn jetty:run -pl obp-api
[Note: How to run via IntelliJ IDEA](docs/glossary/Run via IntelliJ IDEA.md)
[Note: How to run via IntelliJ IDEA](docs/glossary/Run_via_IntelliJ_IDEA.md)
## Run some tests.

View File

@ -3113,8 +3113,8 @@ object Glossary extends MdcLoggable {
val source = scala.io.Source.fromFile(path)
val lines: String = try source.mkString finally source.close()
lines
.replaceAll("PLACEHOLDER_SERVER_URL", getServerUrl)
.replaceAll("PLACEHOLDER_API_ROOT", getObpApiRoot)
.replaceAll("getServerUrl", getServerUrl)
.replaceAll("getObpApiRoot", getObpApiRoot)
}
private def getListOfFiles():List[File] = {
@ -3135,7 +3135,7 @@ object Glossary extends MdcLoggable {
glossaryItems.appendAll(
getListOfFiles().map(file =>
GlossaryItem(
title = file.getName.replace(".md", ""),
title = file.getName.replace(".md", "").replace("_", " "),
description = getContentFromMarkdownFile(file.getPath)
)
)