mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 08:27:12 -07:00
Fix the directory problem.
This commit is contained in:
parent
cdd1bb93d4
commit
8871c47561
2 changed files with 2 additions and 2 deletions
|
@ -44,7 +44,7 @@ sealed class IFileSpec {
|
|||
val result = arrayListOf<File>()
|
||||
val includes = Glob(*spec.toTypedArray())
|
||||
|
||||
if (File(filePath).isDirectory) {
|
||||
if (File(baseDir, filePath).isDirectory) {
|
||||
val orgRootDir = (if (File(filePath).isAbsolute) Paths.get(filePath)
|
||||
else if (baseDir != null) Paths.get(baseDir, filePath)
|
||||
else Paths.get(filePath)).run { normalize() }
|
||||
|
|
|
@ -172,7 +172,7 @@ class IncludedFile(val fromOriginal: From, val toOriginal: To, val specs: List<I
|
|||
val result = arrayListOf<File>()
|
||||
specs.forEach { spec ->
|
||||
// val fullDir = if (directory == null) from else KFiles.joinDir(directory, from)
|
||||
spec.toFiles(directory, from).filter { it.isFile }.forEach { source ->
|
||||
spec.toFiles(directory, from).forEach { source ->
|
||||
result.add(if (source.isAbsolute) source else File(source.path))
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue