-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6db4d2c
commit 73122ae
Showing
17 changed files
with
99 additions
and
111 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,3 +25,4 @@ local.properties | |
.DS_Store | ||
|
||
kotlin-js-store | ||
.kotlin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-bin.zip | ||
networkTimeout=10000 | ||
validateDistributionUrl=true | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 0 additions & 34 deletions
34
plugin/src/main/kotlin/me/tylerbwong/gradle/metalava/Documentation.kt
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
49 changes: 49 additions & 0 deletions
49
plugin/src/main/kotlin/me/tylerbwong/gradle/metalava/task/MetalavaHelpTask.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
package me.tylerbwong.gradle.metalava.task | ||
|
||
import me.tylerbwong.gradle.metalava.extension.MetalavaExtension | ||
import org.gradle.api.Project | ||
import org.gradle.api.model.ObjectFactory | ||
import org.gradle.api.tasks.CacheableTask | ||
import org.gradle.api.tasks.TaskAction | ||
import org.gradle.kotlin.dsl.register | ||
import org.gradle.workers.WorkerExecutor | ||
import javax.inject.Inject | ||
|
||
@CacheableTask | ||
internal abstract class MetalavaHelpTask @Inject constructor( | ||
objectFactory: ObjectFactory, | ||
workerExecutor: WorkerExecutor, | ||
) : BaseMetalavaTask(objectFactory, workerExecutor) { | ||
|
||
init { | ||
group = "other" | ||
description = TASK_DESCRIPTION | ||
} | ||
|
||
@TaskAction | ||
fun metalavaHelp() { | ||
executeMetalavaWork(listOf("--help")) | ||
} | ||
|
||
companion object : MetalavaTaskContainer() { | ||
private const val TASK_NAME = "metalavaHelp" | ||
private const val TASK_DESCRIPTION = "Displays the metalava help message." | ||
|
||
fun register( | ||
project: Project, | ||
objectFactory: ObjectFactory, | ||
extension: MetalavaExtension, | ||
) { | ||
val metalavaClasspath = project.getMetalavaClasspath( | ||
objectFactory, | ||
jarPath = extension.metalavaJarPath.get().ifEmpty { null }, | ||
version = extension.version.get(), | ||
) | ||
if (project.tasks.findByName(TASK_NAME) == null) { | ||
project.tasks.register<MetalavaHelpTask>(TASK_NAME) { | ||
this.metalavaClasspath.from(metalavaClasspath) | ||
} | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.