mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2025-12-19 15:09:18 +00:00
whoops forgot escaping the path
This commit is contained in:
@@ -122,7 +122,7 @@ open class IrisSimpleExecutionEnvironment(
|
|||||||
}
|
}
|
||||||
append(current.segment)
|
append(current.segment)
|
||||||
append(File.separatorChar)
|
append(File.separatorChar)
|
||||||
}
|
}.escapedPath
|
||||||
|
|
||||||
val result = mutableSetOf<String>()
|
val result = mutableSetOf<String>()
|
||||||
val queue = ArrayDeque<Pair<String?, Collection<FileComponents>>>()
|
val queue = ArrayDeque<Pair<String?, Collection<FileComponents>>>()
|
||||||
@@ -132,7 +132,7 @@ open class IrisSimpleExecutionEnvironment(
|
|||||||
val path = pair.first?.let { p -> p + File.separatorChar } ?: ""
|
val path = pair.first?.let { p -> p + File.separatorChar } ?: ""
|
||||||
pair.second.forEach { child ->
|
pair.second.forEach { child ->
|
||||||
val path = path + child.segment
|
val path = path + child.segment
|
||||||
if (child.children.isEmpty()) result.add(path)
|
if (child.children.isEmpty()) result.add(path.escapedPath)
|
||||||
else queue.add(path to child.children)
|
else queue.add(path to child.children)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -157,8 +157,8 @@ open class IrisSimpleExecutionEnvironment(
|
|||||||
return mod.joinToString("\n")
|
return mod.joinToString("\n")
|
||||||
}
|
}
|
||||||
|
|
||||||
private val File.escapedPath
|
private val String.escapedPath
|
||||||
get() = absolutePath.replace("\\", "\\\\").replace("\"", "\\\"")
|
get() = replace("\\", "\\\\").replace("\"", "\\\"")
|
||||||
|
|
||||||
private const val ARTIFACT_ID = $$"local:${it.substringBeforeLast(\".jar\")}:1.0.0"
|
private const val ARTIFACT_ID = $$"local:${it.substringBeforeLast(\".jar\")}:1.0.0"
|
||||||
private val BASE_GRADLE = """
|
private val BASE_GRADLE = """
|
||||||
|
|||||||
Reference in New Issue
Block a user