Compare commits
No commits in common. "10af871d2bde62159473fd63377c1f7cd9a1278e" and "f037c6a724d9bc529f01ba1350c9016085435fea" have entirely different histories.
10af871d2b
...
f037c6a724
@ -1,12 +1,8 @@
|
|||||||
plugins {
|
plugins {
|
||||||
id("kotlin-application")
|
id("kotlin-application")
|
||||||
id("shadow")
|
id("com.github.johnrengelman.shadow") version "6.1.0"
|
||||||
id("native-image")
|
|
||||||
id("release")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
version = "0.0.1-SNAPSHOT"
|
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation("org.slf4j:slf4j-api:2.0.0-alpha1")
|
implementation("org.slf4j:slf4j-api:2.0.0-alpha1")
|
||||||
runtimeOnly("org.slf4j:slf4j-simple:2.0.0-alpha1")
|
runtimeOnly("org.slf4j:slf4j-simple:2.0.0-alpha1")
|
||||||
@ -20,3 +16,27 @@ application {
|
|||||||
mainClass.set("scaffold.ScaffoldKt")
|
mainClass.set("scaffold.ScaffoldKt")
|
||||||
applicationName = "scaffold"
|
applicationName = "scaffold"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.withType<com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar> {
|
||||||
|
archiveBaseName.set("scaffold")
|
||||||
|
archiveClassifier.set("")
|
||||||
|
archiveVersion.set("")
|
||||||
|
}
|
||||||
|
|
||||||
|
task("buildNative") {
|
||||||
|
dependsOn("installShadowDist")
|
||||||
|
|
||||||
|
doLast {
|
||||||
|
exec {
|
||||||
|
commandLine(
|
||||||
|
"native-image",
|
||||||
|
"--no-fallback",
|
||||||
|
"-R:MaxNewSize=32",
|
||||||
|
"--language:js",
|
||||||
|
"-jar",
|
||||||
|
"${project.buildDir}/install/app-shadow/lib/scaffold.jar",
|
||||||
|
"${project.buildDir}/native/scaffold"
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
27
app/resources/init/index.d.ts
vendored
27
app/resources/init/index.d.ts
vendored
@ -5,39 +5,42 @@
|
|||||||
*/
|
*/
|
||||||
declare function echo(message: string): void
|
declare function echo(message: string): void
|
||||||
|
|
||||||
declare interface prompt {
|
/**
|
||||||
|
|
||||||
/**
|
|
||||||
* Prompt a user for text input
|
* Prompt a user for text input
|
||||||
*
|
*
|
||||||
* @param text - The text to display for the prompt
|
* @param text - The text to display for the prompt
|
||||||
* @param def - A default value
|
* @param def - A default value
|
||||||
*/
|
*/
|
||||||
string(text: string, def?: string): string
|
declare function prompt(text: string, def?: string): string
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Prompt a user for text input
|
* Prompt a user for text input
|
||||||
*
|
*
|
||||||
* @param text - The text to display for the prompt
|
* @param text - The text to display for the prompt
|
||||||
* @param def - A default value
|
* @param def - A default value
|
||||||
*/
|
*/
|
||||||
boolean(text: string, def?: boolean): boolean
|
declare function promptBoolean(text: string, def?: boolean): boolean
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Renders a template
|
* Renders a template
|
||||||
*
|
*
|
||||||
* @param name - The template name
|
* @param name - The template name
|
||||||
* @param context - The template context
|
* @param context - The template context
|
||||||
* @param output - The output path, if absent, default to the template name
|
|
||||||
*/
|
*/
|
||||||
declare function render(name: string, context: any, output?: string): string
|
declare function render(name: string, context: any): string
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Write a string to a file
|
||||||
|
*
|
||||||
|
* @param input - The content of the file
|
||||||
|
* @param output - The output path
|
||||||
|
*/
|
||||||
|
declare function write(input: string, output: string): void
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Copy a file
|
* Copy a file
|
||||||
*
|
*
|
||||||
* @param input - The input path
|
* @param input - The input path
|
||||||
* @param output - The output path, if absent, default to the input path
|
* @param output - The output path
|
||||||
*/
|
*/
|
||||||
declare function copy(input: string, output?: string): void
|
declare function copy(input: string, output: string): void
|
||||||
@ -1,7 +1,7 @@
|
|||||||
echo("Example")
|
echo("Example")
|
||||||
|
|
||||||
const name = prompt.string("Project name")
|
const name = prompt("Project name")
|
||||||
|
|
||||||
const ctx = {name: name}
|
const ctx = {name: name}
|
||||||
|
|
||||||
render("README.md", ctx)
|
write(render("README.md", ctx), "README.md")
|
||||||
@ -1,37 +0,0 @@
|
|||||||
package scaffold
|
|
||||||
|
|
||||||
import com.github.ajalt.clikt.core.UsageError
|
|
||||||
import com.github.ajalt.clikt.output.CliktConsole
|
|
||||||
import com.github.ajalt.clikt.output.TermUi
|
|
||||||
import com.github.ajalt.clikt.output.defaultCliktConsole
|
|
||||||
|
|
||||||
class Prompt(private val console: CliktConsole = defaultCliktConsole()) {
|
|
||||||
|
|
||||||
fun string(text: String, default: String?): String = TermUi.prompt(
|
|
||||||
text = text,
|
|
||||||
default = default,
|
|
||||||
console = console
|
|
||||||
) { it }!!
|
|
||||||
|
|
||||||
fun boolean(text: String, default: Boolean?): Boolean {
|
|
||||||
val (defaultString, suffix) = when (default) {
|
|
||||||
true -> "y" to "[Y/n]"
|
|
||||||
false -> "n" to "[y/N]"
|
|
||||||
null -> null to "[y/n]"
|
|
||||||
}
|
|
||||||
|
|
||||||
return TermUi.prompt(
|
|
||||||
"$text $suffix",
|
|
||||||
default = defaultString,
|
|
||||||
showDefault = false,
|
|
||||||
console = console
|
|
||||||
) {
|
|
||||||
when (it.toLowerCase()) {
|
|
||||||
"y" -> true
|
|
||||||
"n" -> false
|
|
||||||
else -> throw UsageError("Can only be [y/n]")
|
|
||||||
}
|
|
||||||
}!!
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -3,6 +3,7 @@ package scaffold.commands
|
|||||||
import com.github.ajalt.clikt.core.CliktCommand
|
import com.github.ajalt.clikt.core.CliktCommand
|
||||||
import com.github.ajalt.clikt.core.ProgramResult
|
import com.github.ajalt.clikt.core.ProgramResult
|
||||||
import com.github.ajalt.clikt.core.UsageError
|
import com.github.ajalt.clikt.core.UsageError
|
||||||
|
import com.github.ajalt.clikt.output.TermUi
|
||||||
import com.github.ajalt.clikt.parameters.arguments.argument
|
import com.github.ajalt.clikt.parameters.arguments.argument
|
||||||
import com.github.ajalt.clikt.parameters.options.convert
|
import com.github.ajalt.clikt.parameters.options.convert
|
||||||
import com.github.ajalt.clikt.parameters.options.option
|
import com.github.ajalt.clikt.parameters.options.option
|
||||||
@ -12,7 +13,6 @@ import com.mitchellbosecke.pebble.loader.FileLoader
|
|||||||
import com.mitchellbosecke.pebble.template.PebbleTemplate
|
import com.mitchellbosecke.pebble.template.PebbleTemplate
|
||||||
import scaffold.Generator
|
import scaffold.Generator
|
||||||
import scaffold.Generators
|
import scaffold.Generators
|
||||||
import scaffold.Prompt
|
|
||||||
import scaffold.scripting.ScriptContext
|
import scaffold.scripting.ScriptContext
|
||||||
import scaffold.scripting.ScriptEngine
|
import scaffold.scripting.ScriptEngine
|
||||||
import java.io.StringWriter
|
import java.io.StringWriter
|
||||||
@ -37,18 +37,49 @@ class GenerateCommand(private val generators: Generators) : CliktCommand("genera
|
|||||||
val scriptContext = object : ScriptContext {
|
val scriptContext = object : ScriptContext {
|
||||||
override fun echo(message: String) = this@GenerateCommand.echo(message)
|
override fun echo(message: String) = this@GenerateCommand.echo(message)
|
||||||
|
|
||||||
override val prompt = Prompt()
|
override fun prompt(text: String, default: String?) = this@GenerateCommand.prompt(text, default)!!
|
||||||
|
|
||||||
override fun render(template: String, ctx: Map<String, Any?>, output: String?) {
|
override fun promptBoolean(text: String, default: Boolean?): Boolean {
|
||||||
val renderedTemplate = pebble.getTemplate(template)(ctx)
|
val suffix = when (default) {
|
||||||
val outputPath = output?.let { outputPathRoot.resolve(it) } ?: outputPathRoot.resolve(template)
|
true -> "[Y/n]"
|
||||||
Files.createDirectories(outputPath.parent)
|
false -> "[y/N]"
|
||||||
Files.writeString(outputPath, renderedTemplate)
|
null -> "[y/n]"
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun copy(input: String, output: String?) {
|
val defaultAsString = when (default) {
|
||||||
|
true -> "y"
|
||||||
|
false -> "n"
|
||||||
|
null -> null
|
||||||
|
}
|
||||||
|
|
||||||
|
return this@GenerateCommand.prompt(
|
||||||
|
"$text $suffix",
|
||||||
|
default = defaultAsString,
|
||||||
|
showDefault = false
|
||||||
|
) {
|
||||||
|
when (it.toLowerCase()) {
|
||||||
|
"y" -> true
|
||||||
|
"n" -> false
|
||||||
|
else -> throw UsageError("Can only be [y/n]")
|
||||||
|
}
|
||||||
|
}!!
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun promptInt(text: String, default: Int?): Int {
|
||||||
|
TODO("Not yet implemented")
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun render(name: String, ctx: Map<String, Any?>) = pebble.getTemplate(name)(ctx)
|
||||||
|
|
||||||
|
override fun write(content: String, output: String) {
|
||||||
|
val outputPath = outputPathRoot.resolve(output)
|
||||||
|
Files.createDirectories(outputPath.parent)
|
||||||
|
Files.writeString(outputPath, content)
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun copy(input: String, output: String) {
|
||||||
val inputPath = generator.treeRoot.resolve(input)
|
val inputPath = generator.treeRoot.resolve(input)
|
||||||
val outputPath = output?.let { outputPathRoot.resolve(it) } ?: outputPathRoot.resolve(inputPath)
|
val outputPath = outputPathRoot.resolve(output)
|
||||||
Files.createDirectories(outputPath.parent)
|
Files.createDirectories(outputPath.parent)
|
||||||
Files.copy(inputPath, outputPath)
|
Files.copy(inputPath, outputPath)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,26 +0,0 @@
|
|||||||
package scaffold.scripting
|
|
||||||
|
|
||||||
import org.graalvm.polyglot.Value
|
|
||||||
import org.graalvm.polyglot.proxy.ProxyExecutable
|
|
||||||
import org.graalvm.polyglot.proxy.ProxyObject
|
|
||||||
import scaffold.Prompt
|
|
||||||
|
|
||||||
class PromptProxyAdapter(private val prompt: Prompt) : ProxyObject {
|
|
||||||
|
|
||||||
override fun getMember(key: String?) = when (key) {
|
|
||||||
"string" -> ProxyExecutable { args ->
|
|
||||||
prompt.string(args[0].asString(), args.getOrNull(1)?.asString())
|
|
||||||
}
|
|
||||||
"boolean" -> ProxyExecutable { args ->
|
|
||||||
prompt.boolean(args[0].asString(), args.getOrNull(1)?.asBoolean())
|
|
||||||
}
|
|
||||||
else -> throw UnsupportedOperationException()
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun getMemberKeys() = arrayOf("string", "boolean")
|
|
||||||
|
|
||||||
override fun hasMember(key: String?): Boolean = key in memberKeys
|
|
||||||
|
|
||||||
override fun putMember(key: String?, value: Value?) = throw UnsupportedOperationException()
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -1,13 +1,14 @@
|
|||||||
package scaffold.scripting
|
package scaffold.scripting
|
||||||
|
|
||||||
import scaffold.Prompt
|
|
||||||
|
|
||||||
interface ScriptContext {
|
interface ScriptContext {
|
||||||
fun echo(message: String)
|
fun echo(message: String)
|
||||||
|
|
||||||
val prompt: Prompt
|
fun prompt(text: String, default: String?): String
|
||||||
|
fun promptBoolean(text: String, default: Boolean?): Boolean
|
||||||
|
fun promptInt(text: String, default: Int?): Int
|
||||||
|
|
||||||
fun render(template: String, ctx: Map<String, Any?>, output: String?)
|
fun render(name: String, ctx: Map<String, Any?>): String
|
||||||
|
|
||||||
fun copy(input: String, output: String?)
|
fun write(content: String, output: String)
|
||||||
|
fun copy(input: String, output: String)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,24 +13,34 @@ class ScriptEngine(private val scriptContext: ScriptContext) {
|
|||||||
|
|
||||||
init {
|
init {
|
||||||
with(context.getBindings("js")) {
|
with(context.getBindings("js")) {
|
||||||
putMember("echo", ProxyExecutable { (message) ->
|
putMember("echo", ProxyExecutable { args ->
|
||||||
scriptContext.echo(message.asString())
|
scriptContext.echo(args[0].asString())
|
||||||
null
|
null
|
||||||
})
|
})
|
||||||
|
|
||||||
putMember("prompt", PromptProxyAdapter(scriptContext.prompt))
|
putMember("prompt", ProxyExecutable { args ->
|
||||||
|
scriptContext.prompt(args[0].asString(), args.getOrNull(1)?.asString())
|
||||||
|
})
|
||||||
|
|
||||||
|
putMember("promptBoolean", ProxyExecutable { args ->
|
||||||
|
scriptContext.promptBoolean(args[0].asString(), args.getOrNull(1)?.asBoolean())
|
||||||
|
})
|
||||||
|
|
||||||
|
putMember("promptInt", ProxyExecutable { args ->
|
||||||
|
scriptContext.promptInt(args[0].asString(), args.getOrNull(1)?.asInt())
|
||||||
|
})
|
||||||
|
|
||||||
putMember("render", ProxyExecutable { args ->
|
putMember("render", ProxyExecutable { args ->
|
||||||
@Suppress("UNCHECKED_CAST")
|
@Suppress("UNCHECKED_CAST")
|
||||||
scriptContext.render(
|
scriptContext.render(args[0].asString(), args[1].`as`(Map::class.java) as Map<String, Any?>)
|
||||||
args[0].asString(),
|
|
||||||
args[1].`as`(Map::class.java) as Map<String, Any?>,
|
|
||||||
args.getOrNull(2)?.asString()
|
|
||||||
)
|
|
||||||
})
|
})
|
||||||
|
|
||||||
putMember("copy", ProxyExecutable { args ->
|
putMember("write", ProxyExecutable { (input, output) ->
|
||||||
scriptContext.copy(args[0].asString(), args.getOrNull(1)?.asString())
|
scriptContext.write(input.asString(), output.asString())
|
||||||
|
})
|
||||||
|
|
||||||
|
putMember("copy", ProxyExecutable { (input, output) ->
|
||||||
|
scriptContext.copy(input.asString(), output.asString())
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,60 +0,0 @@
|
|||||||
@file:Suppress("MemberVisibilityCanBePrivate")
|
|
||||||
|
|
||||||
package scaffold
|
|
||||||
|
|
||||||
import com.github.ajalt.clikt.output.CliktConsole
|
|
||||||
import io.mockk.clearMocks
|
|
||||||
import io.mockk.every
|
|
||||||
import io.mockk.mockk
|
|
||||||
import io.mockk.verify
|
|
||||||
import org.junit.jupiter.api.BeforeEach
|
|
||||||
import org.junit.jupiter.api.Test
|
|
||||||
import org.junit.jupiter.api.TestInstance
|
|
||||||
import org.junit.jupiter.params.ParameterizedTest
|
|
||||||
import org.junit.jupiter.params.provider.CsvSource
|
|
||||||
import strikt.api.expectThat
|
|
||||||
import strikt.assertions.isEqualTo
|
|
||||||
|
|
||||||
@TestInstance(TestInstance.Lifecycle.PER_CLASS)
|
|
||||||
class PromptTest {
|
|
||||||
|
|
||||||
val console = mockk<CliktConsole>()
|
|
||||||
val prompt = Prompt(console)
|
|
||||||
|
|
||||||
@BeforeEach
|
|
||||||
fun beforeEach() = clearMocks(console)
|
|
||||||
|
|
||||||
@CsvSource(
|
|
||||||
value = [
|
|
||||||
"null, answer, answer",
|
|
||||||
"def, answer, answer",
|
|
||||||
"def, '', def"
|
|
||||||
]
|
|
||||||
)
|
|
||||||
@ParameterizedTest(name = "prompt string({argumentsWithNames})")
|
|
||||||
fun `prompt string`(default: String?, answer: String, expectedValue: String) {
|
|
||||||
every { console.promptForLine(any(), any()) } returns answer
|
|
||||||
expectThat(prompt.string("test", default)).isEqualTo(expectedValue)
|
|
||||||
}
|
|
||||||
|
|
||||||
@CsvSource(
|
|
||||||
value = [
|
|
||||||
"null, y, true",
|
|
||||||
"null, n, false",
|
|
||||||
|
|
||||||
"true, '', true",
|
|
||||||
"true, y, true",
|
|
||||||
"true, n, false",
|
|
||||||
|
|
||||||
"false, '', false",
|
|
||||||
"false, y, true",
|
|
||||||
"false, n, false",
|
|
||||||
]
|
|
||||||
)
|
|
||||||
@ParameterizedTest(name = "prompt boolean({argumentsWithNames})")
|
|
||||||
fun `prompt boolean`(default: Boolean?, answer: String, expectedValue: Boolean) {
|
|
||||||
every { console.promptForLine(any(), any()) } returns answer
|
|
||||||
expectThat(prompt.boolean("test", default)).isEqualTo(expectedValue)
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -1,4 +1,4 @@
|
|||||||
@file:Suppress("MemberVisibilityCanBePrivate")
|
@file:Suppress("MemberVisibilityCanBePrivate", "PackageDirectoryMismatch")
|
||||||
|
|
||||||
package scaffold.scripting
|
package scaffold.scripting
|
||||||
|
|
||||||
@ -10,15 +10,11 @@ import org.junit.jupiter.api.BeforeEach
|
|||||||
import org.junit.jupiter.api.Test
|
import org.junit.jupiter.api.Test
|
||||||
import org.junit.jupiter.api.TestInstance
|
import org.junit.jupiter.api.TestInstance
|
||||||
import org.junit.jupiter.api.TestInstance.Lifecycle
|
import org.junit.jupiter.api.TestInstance.Lifecycle
|
||||||
import scaffold.Prompt
|
|
||||||
|
|
||||||
@TestInstance(Lifecycle.PER_CLASS)
|
@TestInstance(Lifecycle.PER_CLASS)
|
||||||
class ScriptEngineTest {
|
class ScriptEngineTest {
|
||||||
|
|
||||||
val scriptContext = mockk<ScriptContext>().also {
|
val scriptContext = mockk<ScriptContext>()
|
||||||
every { it.prompt } returns Prompt()
|
|
||||||
}
|
|
||||||
|
|
||||||
val scriptEngine = ScriptEngine(scriptContext)
|
val scriptEngine = ScriptEngine(scriptContext)
|
||||||
|
|
||||||
@BeforeEach
|
@BeforeEach
|
||||||
@ -36,7 +32,7 @@ class ScriptEngineTest {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun render() {
|
fun render() {
|
||||||
every { scriptContext.render("test", match { it["something"] == "hello" }, null) } returns Unit
|
every { scriptContext.render("test", match { it["something"] == "hello" }) } returns "blah"
|
||||||
|
|
||||||
val script = """
|
val script = """
|
||||||
const ctx = {
|
const ctx = {
|
||||||
@ -48,7 +44,27 @@ class ScriptEngineTest {
|
|||||||
|
|
||||||
scriptEngine.eval(script)
|
scriptEngine.eval(script)
|
||||||
|
|
||||||
verify { scriptContext.render(any(), any(), any()) }
|
verify { scriptContext.render(any(), any()) }
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
fun prompt() {
|
||||||
|
every { scriptContext.prompt("a", null) } returns "a"
|
||||||
|
|
||||||
|
val script = "prompt('a')"
|
||||||
|
scriptEngine.eval(script)
|
||||||
|
|
||||||
|
verify { scriptContext.prompt(any(), null) }
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
fun promptWithDefault(){
|
||||||
|
every { scriptContext.prompt("a", "default") } returns "default"
|
||||||
|
|
||||||
|
val script = "prompt('a', 'default')"
|
||||||
|
scriptEngine.eval(script)
|
||||||
|
|
||||||
|
verify { scriptContext.prompt(any(), any()) }
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,5 +13,4 @@ repositories {
|
|||||||
dependencies {
|
dependencies {
|
||||||
implementation(platform("org.jetbrains.kotlin:kotlin-bom:1.4.31"))
|
implementation(platform("org.jetbrains.kotlin:kotlin-bom:1.4.31"))
|
||||||
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:1.4.31")
|
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:1.4.31")
|
||||||
implementation("com.github.jengelman.gradle.plugins:shadow:6.1.0")
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,21 +0,0 @@
|
|||||||
task("buildNative") {
|
|
||||||
dependsOn("installShadowDist")
|
|
||||||
|
|
||||||
outputs.file("${buildDir}/native/scaffold")
|
|
||||||
|
|
||||||
doLast {
|
|
||||||
val graalvmHome = System.getenv("GRAALVM_HOME") ?: error("GRAALVM_HOME is not set")
|
|
||||||
|
|
||||||
exec {
|
|
||||||
commandLine(
|
|
||||||
"${graalvmHome}/bin/native-image",
|
|
||||||
"--no-fallback",
|
|
||||||
"-R:MaxNewSize=32",
|
|
||||||
"--language:js",
|
|
||||||
"-jar",
|
|
||||||
"${buildDir}/install/app-shadow/lib/scaffold.jar",
|
|
||||||
"${buildDir}/native/scaffold"
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,7 +0,0 @@
|
|||||||
tasks.register<Zip>("release") {
|
|
||||||
dependsOn("buildNative")
|
|
||||||
|
|
||||||
archiveFileName.set("scaffold-${archiveVersion.get()}-linux.zip")
|
|
||||||
destinationDirectory.set(file("$buildDir/release"))
|
|
||||||
from("$buildDir/native/scaffold")
|
|
||||||
}
|
|
||||||
@ -1,11 +0,0 @@
|
|||||||
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
|
|
||||||
|
|
||||||
plugins {
|
|
||||||
id("com.github.johnrengelman.shadow")
|
|
||||||
}
|
|
||||||
|
|
||||||
tasks.withType<ShadowJar> {
|
|
||||||
archiveBaseName.set("scaffold")
|
|
||||||
archiveClassifier.set("")
|
|
||||||
archiveVersion.set("")
|
|
||||||
}
|
|
||||||
@ -1,3 +0,0 @@
|
|||||||
org.gradle.jvmargs=-Xmx2048M -XX:MaxPermSize=512m -Dfile.encoding=UTF-8
|
|
||||||
org.gradle.caching=true
|
|
||||||
org.gradle.parallel=true
|
|
||||||
Loading…
x
Reference in New Issue
Block a user