1
0
Fork 0
mirror of https://github.com/ethauvin/kobalt.git synced 2025-04-25 07:57:12 -07:00

Merge pull request #458 from McPringle/master

Fixing the WAR filename could contain a `null` version #456
This commit is contained in:
Cedric Beust 2017-11-05 07:02:08 -08:00 committed by GitHub
commit 05f8e2f41a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -17,7 +17,8 @@ class Archives {
@ExportedProjectProperty(doc = "The name of the a jar file with a main() method", type = "String")
const val JAR_NAME_WITH_MAIN_CLASS = "jarNameWithMainClass"
fun defaultArchiveName(project: Project) = project.name + "-" + project.version
fun defaultArchiveName(project: Project) = project.name +
if (project.version == null || project.version == "") "" else "-${project.version}"
fun generateArchive(project: Project,
context: KobaltContext,