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

Warnings.

This commit is contained in:
Cedric Beust 2015-11-07 19:49:00 -08:00
parent af8ad34ac3
commit 4c24dd704d
5 changed files with 6 additions and 6 deletions

View file

@ -57,7 +57,7 @@ class GetDependenciesCommand @Inject constructor(val executors: KobaltExecutors,
allDeps(project.testDependencies).map { toDependencyData(it, "testCompile") } +
allDeps(project.testProvidedDependencies).map { toDependencyData(it, "testProvided") }
projects.add(ProjectData(project.name!!, allDependencies))
projects.add(ProjectData(project.name, allDependencies))
}
log(1, "Returning BuildScriptInfo")
val result = toCommandData(Gson().toJson(GetDependenciesData(projects)))

View file

@ -27,6 +27,6 @@ public class JavaProject(
: Project(name, version, directory, buildDirectory, group, artifactId, packaging, dependencies,
".java", projectInfo = JavaProjectInfo()) {
override public fun toString() = toString("JavaProject", "name", name!!)
override public fun toString() = toString("JavaProject", "name", name)
}

View file

@ -36,7 +36,7 @@ class KotlinPlugin @Inject constructor(
@Task(name = TASK_COMPILE, description = "Compile the project")
fun taskCompile(project: Project): TaskResult {
copyResources(project, JvmCompilerPlugin.SOURCE_SET_MAIN)
val classpath = jvmCompiler.calculateDependencies(project, context!!, project.compileDependencies,
val classpath = jvmCompiler.calculateDependencies(project, context, project.compileDependencies,
project.compileProvidedDependencies)
val projectDirectory = java.io.File(project.directory)

View file

@ -224,7 +224,7 @@ class PackagingPlugin @Inject constructor(val dependencyManager : DependencyMana
includedFiles: List<IncludedFile>,
expandJarFiles : Boolean = false,
outputStreamFactory: (OutputStream) -> ZipOutputStream = DEFAULT_STREAM_FACTORY) : File {
val fullArchiveName = archiveName ?: arrayListOf(project.name!!, project.version!!).joinToString("-") + suffix
val fullArchiveName = archiveName ?: arrayListOf(project.name, project.version!!).joinToString("-") + suffix
val archiveDir = libsDir(project)
val result = File(archiveDir.path, fullArchiveName)
val outStream = outputStreamFactory(FileOutputStream(result))

View file

@ -69,7 +69,7 @@ public class JCenterApi @Inject constructor (@Nullable @Assisted("username") val
// }
fun uploadMaven(project: Project, files: List<File>, config: JCenterConfig?) : TaskResult {
if (! packageExists(project.name!!)) {
if (! packageExists(project.name)) {
throw KobaltException("Couldn't find a package called ${project.name} on bintray, please create one first" +
" as explained at https://bintray.com/docs/usermanual/uploads/uploads_creatinganewpackage.html")
}
@ -79,7 +79,7 @@ public class JCenterApi @Inject constructor (@Nullable @Assisted("username") val
UnauthenticatedJCenterApi.BINTRAY_URL_API_CONTENT,
username!!,
"maven",
project.name!!,
project.name,
project.version!!,
project.group!!.replace(".", "/"),
project.artifactId!!,