mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 08:27:12 -07:00
NPE.
This commit is contained in:
parent
0ff3138f1f
commit
4fb5dbf7bc
1 changed files with 4 additions and 4 deletions
|
@ -11,20 +11,20 @@ open class SimpleDep(open val mavenId: MavenId) : UnversionedDep(mavenId.groupId
|
|||
|
||||
val version: String get() = mavenId.version!!
|
||||
|
||||
private fun toFile(v: String, s: String, suffix: String) : String {
|
||||
private fun toFile(v: String, snapshotVersion: String?, suffix: String) : String {
|
||||
val fv = if (v.contains("SNAPSHOT")) v.replace("SNAPSHOT", "") else v
|
||||
val result = Strings.join("/", arrayListOf(toDirectory(v, false) +
|
||||
artifactId + "-" + fv + s + suffix))
|
||||
artifactId + "-" + fv + (snapshotVersion ?: "") + suffix))
|
||||
return result
|
||||
}
|
||||
|
||||
fun toPomFile(v: String) = toFile(v, "", ".pom")
|
||||
|
||||
fun toPomFile(r: RepoFinder.RepoResult) = toFile(r.version!!.version, r.snapshotVersion!!.version, ".pom")
|
||||
fun toPomFile(r: RepoFinder.RepoResult) = toFile(r.version!!.version, r.snapshotVersion?.version, ".pom")
|
||||
|
||||
fun toJarFile(v: String = version) = toFile(v, "", suffix)
|
||||
|
||||
fun toJarFile(r: RepoFinder.RepoResult) = toFile(r.version!!.version, r.snapshotVersion!!.version, suffix)
|
||||
fun toJarFile(r: RepoFinder.RepoResult) = toFile(r.version!!.version, r.snapshotVersion?.version, suffix)
|
||||
|
||||
fun toPomFileName() = "$artifactId-$version.pom"
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue