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 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180
|
group = 'org.tmatesoft.svnkit'
version = '1.8.6'
project.ext {
release = true
target = '1.6'
compatibleSvnVersion = '1.8.1'
}
apply from: 'build.pom.gradle'
buildscript {
apply from: 'build.defaults.gradle'
configurations.all {
resolutionStrategy {
cacheChangingModulesFor 0, 'seconds'
cacheDynamicVersionsFor 0, 'seconds'
}
}
repositories {
maven {
url project.ext.buildPluginRepositoryURL
}
}
dependencies { classpath 'org.tmatesoft.build:build:0.9.9' }
}
task wrapper(type: Wrapper) {}
def javaProjects() {
return subprojects - project(':svnkit-distribution')
}
allprojects {
apply plugin : 'base'
apply plugin : 'build'
}
configure(javaProjects() + rootProject) {
apply plugin: 'eclipse'
apply plugin: 'idea'
gradle.taskGraph.whenReady { taskGraph ->
taskGraph.allTasks.each { task ->
if (task.name == 'eclipseWtpComponent') {
task.enabled = false
}
if (task.name == 'eclipseWtpFacet') {
task.enabled = false
}
}
}
}
configure(javaProjects()) {
apply plugin : 'java'
apply plugin : 'signing'
sourceCompatibility = target
targetCompatibility = target
configurations {
sources
javadocs
}
task sourcesJar(type: Jar) {
description = 'Builds Java Sources Jar'
from sourceSets.main.java.srcDirs
classifier = 'sources'
}
task javadocJar(type: Jar, dependsOn: javadoc) {
description="Builds Javadoc Jar"
from "$docsDir/javadoc"
classifier = 'javadoc'
}
jar {
metaInf {
from rootProject.file('LICENSE.txt')
}
}
artifacts { sources sourcesJar }
}
project(':svnkit') {
dependencies {
compile 'de.regnis.q.sequence:sequence-library:1.0.3'
compile 'org.tmatesoft.sqljet:sqljet:1.1.10'
compile 'net.java.dev.jna:jna:4.1.0'
compile 'net.java.dev.jna:jna-platform:4.1.0'
compile 'com.trilead:trilead-ssh2:1.0.0-build217'
compile('com.jcraft:jsch.agentproxy.connector-factory:0.0.7') {
exclude group: 'net.java.dev.jna'
}
compile 'com.jcraft:jsch.agentproxy.svnkit-trilead-ssh2:0.0.7'
testCompile 'junit:junit:4.8'
}
artifacts { maven jar, sourcesJar, javadocJar }
}
project(':svnkit-javahl16') {
dependencies {
compile project(path: ':svnkit')
compile 'org.apache.subversion:svn-javahl-api:1.8.1'
testCompile 'org.apache.subversion:svn-javahl-tests:1.8.1'
}
artifacts { maven jar, sourcesJar, javadocJar }
}
project(':svnkit-cli') {
dependencies {
compile project(path: ':svnkit')
}
artifacts { maven jar, sourcesJar, javadocJar }
}
project(':svnkit-dav') {
apply plugin: 'war'
dependencies {
compile project(path: ':svnkit')
compile 'javax.servlet:servlet-api:2.5'
}
artifacts { maven war }
}
project(':svnkit-test') {
dependencies {
compile project(path: ':svnkit-cli')
}
sourcesJar.enabled=false
}
project(':svnkit-osgi') {
sourcesJar.enabled=false
artifacts { maven jar }
}
project(':svnkit-distribution') {
configurations {
binaries
sources
scripts
osgi
}
dependencies {
binaries project(path: ':svnkit')
binaries project(path: ':svnkit-cli')
binaries project(path: ':svnkit-javahl16', configuration: 'archives')
sources project(path: ':svnkit', configuration: 'sources')
sources project(path: ':svnkit-cli', configuration: 'sources')
sources project(path: ':svnkit-javahl16', configuration: 'sources')
scripts project(path: ':svnkit-cli', configuration: 'scripts')
osgi project(path: ':svnkit-osgi', configuration: 'archives')
osgi 'com.trilead:trilead-ssh2-osgi:1.0.0-build217'
osgi 'org.tmatesoft.sqljet:sqljet-osgi:1.1.10'
osgi 'net.java.dev.jna:jna-osgi:4.1.0'
}
}
task publish(dependsOn: [':svnkit-distribution:buildAll']) {
enabled = project.hasProperty('to')
} << {
File toDir = new File(project.properties['to'])
delete(toDir)
toDir.mkdirs()
ant.unzip(src: new File(project(':svnkit-distribution').distsDir, "svnkit-${version}-all.zip"), dest: toDir.absolutePath) {
cutdirsmapper(dirs: '1')
}
ant.chmod(dir: new File(toDir, 'bin').absolutePath, perm: 'ugo+rx', includes: '**/**', excludes: '**/*.bat')
}
|