mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2025-09-04 15:49:41 +00:00
refactor and fixes
This commit is contained in:
@@ -35,7 +35,7 @@ val templatesFolders = mutableListOf<File>()
|
||||
var extensions: List<String>? = null
|
||||
var skipPrompts: Boolean = false
|
||||
val commandLineArgs = mutableMapOf<String, String>()
|
||||
val globalEnvs = System.getenv()
|
||||
val globalEnvs = System.getenv().toMutableMap()
|
||||
|
||||
fun String.replaceWithVariables(envs: Map<String, String>): String {
|
||||
var currentString = this
|
||||
@@ -183,7 +183,7 @@ fun readParameters() {
|
||||
|
||||
readParameters()
|
||||
|
||||
val envs: MutableMap<String, String> = envFile ?.let { readEnvs(it.readText(), null) } ?.toMutableMap() ?: mutableMapOf()
|
||||
val envs: MutableMap<String, String> = (envFile ?.let { readEnvs(it.readText(), null) } ?: (globalEnvs + commandLineArgs)).toMutableMap()
|
||||
|
||||
println(
|
||||
"""
|
||||
|
Reference in New Issue
Block a user