Quantcast
Channel: Gradle Forums - Latest posts
Browsing all 19845 articles
Browse latest View live

How call TaskInternal.execute() when gradle update to 5.0+

Actually, I want to reuse JavaCompile Task. I set sourceDir and destinationDir of this task by reflection. So when I call javaCompile.execute(), this task will compile my code which generated by this...

View Article


Android build - why dependency resolution take so long

Api vs implementation - You mean in the dependency phase? If yes, then ok. List of external plugins or dependencies: com.android.application com.android.library kotlin-android kotlin-kapt maven...

View Article


Android build - filter unnecessary created tasks

List of external plugins or dependencies: com.android.application com.android.library kotlin-android kotlin-kapt maven kotlin-android-extensions com.android.tools.build:gradle:3.5.1...

View Article

Gradle distributions downloaded every time build executes

Hi @vs777 Have you found any solution yet? I have the same issue with gitlab.

View Article

Large Kotlin build - how to structure

For Kuberig (https://github.com/teyckmans/kuberig) which is a Gradle plugin to define/deploy to kubernetes/openshift using a Kotlin DSL to define your resources. I have created an other Gradle plugin...

View Article


How call TaskInternal.execute() when gradle update to 5.0+

That’s not how Gradle works… Each task will run either once or not at all for each build execution. A task will never run twice (unless you hack a call to Task.execute()) If you want to run a task...

View Article

Divide a fileTree into parts to run in separate ant batches

Thanks so much. Is there a way to define a separate system property per batch? I want to set a runner number. I tried to put sysProperty(key: “runner”, value: i) in the batchtest block, where the...

View Article

How call TaskInternal.execute() when gradle update to 5.0+

The purpose of my plugin is writing code automatically, compiling this codes and generating the jar for my teammate use. I combined all this jobs in one Task. So I have to reuse the CompileJava and...

View Article


How call TaskInternal.execute() when gradle update to 5.0+

As an example, the java plugin adds two JavaCompile tasks (compileJava and compileTestJava)

View Article


Divide a fileTree into parts to run in separate ant batches

That sounds like an ant question

View Article

Get duration of a task in java

Hey there, I’m using the gradle API org.gradle.tooling in Java and I would like to be able to get the duration of each task of a build. Is there any way to do so? thanks

View Article

I can't seem to share test code between projects in a multi-project build

@Lance, that would be wrong, because that way gw assemble also compiles test code, which shouldn’t be the case. I still think the test jar approach is the cleanest.

View Article

Image may be NSFW.
Clik here to view.

Can we create a container (a library) in Eclipse and add jars by Gradle task?

I created a JPMS Gradle project with Buildship in Eclipse that works very well with Gradle tasks. But if I want to test my code directly, on the fly, without going through a test task, I get the...

View Article


Logging in gradle plugin

So does that mean that I can’t enable the logs of my plugin (via configuration or xml) alone and disable all of the other logs that Gradle might output (processing, other plugins, etc…) during the...

View Article

Programmatically add a dependency as non-transitive (via Java code)

I want to do something like dependencies { compileOnly (project(":potato")) { transitive = false } } in Java but I can’t seem to figure out how to… I’m looking at:...

View Article


Programmatically add a dependency as non-transitive (via Java code)

Hrmm, just realized I can access the underlying dependency object returned by add and cast it and then set it to transitive = false? Dependency dep = project.getDependencies.add("name", potatoProject)...

View Article

Running tests of included builds sequent

I am running my tests from a parent directory which includes all the sub builds with includeBuild. I cannot figure out a way to avoid they run in parallel. I have all sorts of resource conflicts like...

View Article


Optimizing Build Speed

What’s the standard pattern for keeping builds fast and optional tasks off the standard build path? We have spotbugs, checkstyle, deployment readiness checks and springboot shadow jars which all need...

View Article

Launching groovyConsole from gradle (with gradle compile classpath)

This is my build file: /* This build file was generated by the Gradle ‘init’ task. This generated file contains a sample Java Library project to get you started. For more details take a look at the...

View Article

Image may be NSFW.
Clik here to view.

Logging in gradle plugin

ahasbini: „…So does that mean that I can’t enable the logs of my plugin (via configuration or xml) alone and disable all of the other logs that Gradle might output (processing, other plugins, etc…)...

View Article
Browsing all 19845 articles
Browse latest View live