diff --git a/src/main/scala/com/skyline/warlangmod/Output.scala b/src/main/scala/com/skyline/warlangmod/Output.scala new file mode 100644 index 0000000..b421964 --- /dev/null +++ b/src/main/scala/com/skyline/warlangmod/Output.scala @@ -0,0 +1,16 @@ +package com.skyline.warlangmod + +trait Output { + def write(filename: String): Unit +} + +object Output { + def apply(): Output = new Output { + import java.io.FileWriter + override def write(filename: String): Unit = { + val updatedFile = new FileWriter(filename) + updatedFile.write(uptodateModdedTranslationFile.render()) + updatedFile.close() + } + } +}