forked from centic9/jgit-cookbook
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
35 lines (28 loc) · 1.06 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
apply plugin: 'java'
sourceCompatibility = 1.8
repositories {
mavenCentral()
maven {
url "https://repo.eclipse.org/content/groups/releases/"
}
}
dependencies {
compile 'org.eclipse.jgit:org.eclipse.jgit:5.0.3.201809091024-r'
compile 'org.eclipse.jgit:org.eclipse.jgit.archive:5.0.3.201809091024-r'
compile 'commons-io:commons-io:2.6'
compile 'org.slf4j:slf4j-simple:1.7.25'
// optional dependency of commons-compress which is needed by JGit
compile 'org.tukaani:xz:1.8'
testCompile 'junit:junit:4.12'
}
task wrapper(type: Wrapper) {
gradleVersion = '4.6'
}
task adjustWrapperPropertiesFile << {
ant.replaceregexp(match:'^#.*', replace:'', flags:'g', byline:true) {
fileset(dir: project.projectDir, includes: 'gradle/wrapper/gradle-wrapper.properties')
}
new File(project.projectDir, 'gradle/wrapper/gradle-wrapper.properties').with { it.text = it.readLines().findAll { it }.sort().join('\n') }
ant.fixcrlf(file: 'gradle/wrapper/gradle-wrapper.properties', eol: 'lf')
}
wrapper.finalizedBy adjustWrapperPropertiesFile