Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [gradle]

Gradle is a project build automation tool that uses a Groovy DSL. Gradle build scripts support Maven and Ivy repositories as well as plain file system for dependency management.

2 votes
1 answer
7k views

Running tomcat jasper task (jspc) with gradle build

I'm trying to compile our jsp files using jspc within gradle but am getting an exception. Here is the pertinent gradle section //tomcatHome is defined in gradle.properties ant.tomcatHome = "${...
Josh's user avatar
  • 2,942
6 votes
3 answers
2k views

How do you view SLF4J logging output from project source during a Gradle build?

I'm using SLF4J for logging messages in my Java project and building the project with Gradle. I'm trying to debug something and I'd like to be able to see logging messages that are in my Java source ...
Matt W's user avatar
  • 6,098
219 votes
17 answers
138k views

Multi-project test dependencies with gradle

I have a multi-project configuration and I want to use gradle. My projects are like this: Project A -> src/main/java -> src/test/java Project B -> src/main/java (depends on src/main/java on ...
mathd's user avatar
  • 2,535
6 votes
5 answers
17k views

How can I pass JVM system properties on to my tests?

I have the following task task testGeb(type:Test) { jvmArgs '-Dgeb.driver=firefox' include "geb/**/*.class" testReportDir = new File(testReportDir, "gebtests") } The system property doesn't ...
Ray Nicholus's user avatar
  • 19.8k
8 votes
3 answers
2k views

IZPack with Gradle

Has anyone used IZPack with Gradle? And how easy is it to use? Any example code?
Blaine Mucklow's user avatar
14 votes
3 answers
19k views

Selecting specific tests to run in gradle

I'm trying to fix our messy failing test runs, and, unfortunately, I'm very new to gradle. We currently have testng, junit, and I'd like to add some spock tests to the mix as well. I'm not quite ...
Ray Nicholus's user avatar
  • 19.8k
8 votes
3 answers
17k views

How can I create a pathing jar in Gradle

When running groovyc in a Windows env, I am running into issues due to the length of the classpath, in my situation. I would like to work around this by creating a pathing jar, and then put that jar ...
Ray Nicholus's user avatar
  • 19.8k
9 votes
5 answers
11k views

Gradle Replace text in jsp using filter

I have a jsp that contains a css link that looks like <link type="text/css" href="/css/login-min.css" rel="stylesheet" /> In order to keep browsers from caching the css file we replace login-...
Josh's user avatar
  • 2,942
13 votes
3 answers
6k views

Gradle vs. Gant

I'm working on a Linux/Apache/MySQL/Grails application and have the choice of build tools. I'm looking at Gradle or Gant. They look very similar to me, so I'm not sure what differentiates them. ...
jmq's user avatar
  • 10.3k
2 votes
1 answer
1k views

can't apply gradle application plugin to my build script

my build.gradle looks like: apply plugin: 'java' apply plugin: 'eclipse' apply plugin: 'application' ...... when I execute gradle build I get the following output: FAILURE: Build failed with an ...
Yonatan Maman's user avatar
1 vote
3 answers
951 views

Using DBDeploy in Gradle with hibernate as the ORM

I am looking to use a versioned database migrations tool like DBdeploy in a java project which uses Hibernate as the ORM and uses Gradle as the build system. I am unable to lookup any documentation on ...
Ritesh M Nayak's user avatar
9 votes
1 answer
5k views

Including generated code in JAR with Gradle

I wrote a simple gradle task to generate thrift files: task generateThrift << { thriftFiles = fileTree(dir: 'src/main/thrift').matching { include '**/*.thrift' } exec { executable = '...
Eric Hauser's user avatar
  • 5,571
1 vote
4 answers
3k views

Problem with Gradle and UNC path under Jenkins

Got this error after moving %JENKINS_HOME% to a UNC from a local directory. Any idea how to fix this? We use Windows server 2008 and it seems like there is no way to do hard link to a UNC under ...
hb5fa's user avatar
  • 329
86 votes
9 answers
71k views

Gradle Test Dependency

I have two projects, project A and Project B. Both are written in groovy and use gradle as their build system. Project A requires project B. This holds for both the compile and test code. How can ...
Dr. Simon Harrer's user avatar
28 votes
5 answers
41k views

gradle doesn't work in Intellij - problems with JAVA_HOME

I can run gradle from a command line to see its version. I can run, compile and debug a grails app in IntelliJ (version 10.0 or version 10.2) I installed the IntelliJ Gradle Plugin. Whenever I try to ...
Andrew's user avatar
  • 2,363

15 30 50 per page