[skip ci] change default desktop config to desktop-config.yaml

merge-requests/1/merge
ansgarz 2 years ago
parent d572705a15
commit 3f3974794a

@ -11,13 +11,13 @@ import java.io.FileWriter
* Returns WorkplaceConfig; data for config is read from specified file.
* Throws exceptions FileNotFoundException, SerializationException if file is not found resp. cannot be parsed.
*/
internal fun getConfig(filename: String = "WorkplaceConfig.yaml"): DesktopConfig {
return readFromFile(filename).yamlToType<DesktopConfig>()
internal fun getConfig(filename: String = "desktop-config.yaml"): DesktopConfig {
return readFromFile(filename).yamlToType()
}
@Suppress("unused")
internal fun writeConfig(config: DesktopConfig, fileName: String = "WorkplaceConfigExample.yaml") {
internal fun writeConfig(config: DesktopConfig, fileName: String = "desktop-config.yaml") {
FileWriter(fileName).use {
it.write(
Yaml.default.encodeToString(
@ -26,5 +26,4 @@ internal fun writeConfig(config: DesktopConfig, fileName: String = "WorkplaceCon
)
)
}
}
Loading…
Cancel
Save