mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 16:28:12 -07:00
Fix file dependency.
This commit is contained in:
parent
97ec031c52
commit
62ab568bfb
1 changed files with 6 additions and 1 deletions
|
@ -27,7 +27,12 @@ class DependencyManager @Inject constructor(val executors: KobaltExecutors, val
|
||||||
override fun create(id: String, project: Project?) : IClasspathDependency {
|
override fun create(id: String, project: Project?) : IClasspathDependency {
|
||||||
if (id.startsWith(FileDependency.PREFIX_FILE)) {
|
if (id.startsWith(FileDependency.PREFIX_FILE)) {
|
||||||
val path = if (project?.directory != null) {
|
val path = if (project?.directory != null) {
|
||||||
File(project!!.directory, id.substring(FileDependency.PREFIX_FILE.length))
|
val idPath = id.substring(FileDependency.PREFIX_FILE.length)
|
||||||
|
if (! File(idPath).isAbsolute) {
|
||||||
|
File(project!!.directory, idPath)
|
||||||
|
} else {
|
||||||
|
File(idPath)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
File(id.substring(FileDependency.PREFIX_FILE.length))
|
File(id.substring(FileDependency.PREFIX_FILE.length))
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue