Anyone know what I'm doing wrong here, trying to c...
# ktor
g
Anyone know what I'm doing wrong here, trying to capture the output from the command, always gettiung the stream id instead of the stream no matter what I try. Ultimately trying to spin up local docker image after build but presently just trying to run basic commands so I know that part is working:
Copy code
register<Exec>("runFatJarLocallyInDocker") {
    group = "application"
    dependsOn(mutableSetOf<Any>("buildFatJar"))
    commandLine = mutableListOf("cmd", "dir")
    val std = standardOutput
    doLast {
        println()
        println("Output: ${std.toString()}")
        println("Error: ${errorOutput.toString()}")
    }

    /*
    commandLine(
        "docker dir",
        "docker build -t ${project.name}-fat.jar",
        "docker run -m512M --cpus 2 -it -p 8080:8080 --rm ${project.name}-fat.jar"
    )*/
}
Output: org.gradle.process.internal.streams.SafeStreams$2@33e60aef
Error: org.gradle.process.internal.streams.SafeStreams$1@6fed0bb8