|
1 | | -buildscript { |
2 | | - repositories { |
3 | | - jcenter() |
4 | | - } |
5 | | - dependencies { |
6 | | - classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.4' |
7 | | - } |
8 | | -} |
9 | | - |
10 | | -apply plugin: 'java' |
11 | | -apply plugin: 'maven-publish' |
12 | | -apply plugin: 'com.jfrog.bintray' |
13 | | - |
14 | | -archivesBaseName = 'databox-sdk' |
15 | | -group = 'com.databox' |
16 | | -version = '2.0' |
17 | | - |
18 | | -repositories { |
19 | | - mavenCentral() |
20 | | -} |
21 | | - |
22 | | -allprojects { |
23 | | - apply plugin: 'java' |
24 | | - sourceCompatibility = 1.7 |
25 | | - targetCompatibility = 1.7 |
26 | | -} |
27 | | - |
28 | | -dependencies { |
29 | | - compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.+' |
30 | | - testCompile group: 'junit', name: 'junit', version: '4.+' |
31 | | -} |
32 | | - |
33 | | -bintray { |
34 | | - user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : "" |
35 | | - key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : "" |
36 | | - // configurations = ['archives'] |
37 | | - publications = ['mavenJava'] |
38 | | - |
39 | | - pkg { |
40 | | - repo = 'databox' |
41 | | - name = 'databox-sdk' |
42 | | - userOrg = 'databox' |
43 | | - licenses = ['MIT'] |
44 | | - vcsUrl = 'https://github.com/databox/databox-java.git' |
45 | | - version { |
46 | | - name = '2.0' |
47 | | - desc = 'Databox Java SDK' |
48 | | - released = new Date() |
49 | | - } |
50 | | - } |
51 | | -} |
52 | | - |
53 | | -task sourcesJar(type: Jar, dependsOn: classes) { |
54 | | - classifier = 'sources' |
55 | | - from sourceSets.main.allSource |
56 | | -} |
57 | | - |
58 | | -task javadocJar(type: Jar, dependsOn: javadoc) { |
59 | | - classifier = 'javadoc' |
60 | | - from javadoc.destinationDir |
61 | | -} |
62 | | - |
63 | | -artifacts { |
64 | | - archives sourcesJar, javadocJar |
65 | | -} |
66 | | - |
67 | | -def projectUrl = "https://github.com/databox/databox-java" |
68 | | - |
69 | | -publishing{ |
70 | | - publications { |
71 | | - mavenJava(MavenPublication) { |
72 | | - from components.java |
73 | | - |
74 | | - artifact sourcesJar { |
75 | | - classifier "sources" |
76 | | - } |
77 | | - |
78 | | - artifact javadocJar { |
79 | | - classifier "javadoc" |
80 | | - } |
81 | | - |
82 | | - pom.withXml { |
83 | | - asNode().children().last() + { |
84 | | - resolveStrategy = Closure.DELEGATE_FIRST |
85 | | - name 'Databox Java SDK' |
86 | | - description 'Java SDK for interacting with the Databox Push API.' |
87 | | - url projectUrl |
88 | | - scm { |
89 | | - url projectUrl |
90 | | - connection projectUrl |
91 | | - developerConnection projectUrl |
92 | | - } |
93 | | - licenses { |
94 | | - license { |
95 | | - name 'The MIT License (MIT)' |
96 | | - url 'http://rem.mit-license.org' |
97 | | - distribution 'repo' |
98 | | - } |
99 | | - } |
100 | | - developers { |
101 | | - developer { |
102 | | - id 'otobrglez' |
103 | | - name 'Oto Brglez' |
104 | | - |
105 | | - } |
106 | | - } |
107 | | - } |
108 | | - } |
109 | | - } |
110 | | - } |
111 | | -} |
112 | | - |
| 1 | +buildscript { |
| 2 | + repositories { |
| 3 | + jcenter() |
| 4 | + } |
| 5 | + dependencies { |
| 6 | + classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.4' |
| 7 | + } |
| 8 | +} |
| 9 | + |
| 10 | +apply plugin: 'java' |
| 11 | +apply plugin: 'maven-publish' |
| 12 | +apply plugin: 'com.jfrog.bintray' |
| 13 | + |
| 14 | +// apply plugin: 'checkstyle' |
| 15 | +apply plugin: 'findbugs' |
| 16 | +// apply plugin: 'pmd' |
| 17 | + |
| 18 | +def defaultEncoding = 'UTF-8' |
| 19 | +[compileJava, compileTestJava]*.options*.encoding = defaultEncoding |
| 20 | + |
| 21 | +archivesBaseName = 'databox-sdk' |
| 22 | +group = 'com.databox' |
| 23 | +version = '2.1' |
| 24 | + |
| 25 | +repositories { |
| 26 | + mavenCentral() |
| 27 | +} |
| 28 | + |
| 29 | +allprojects { |
| 30 | + apply plugin: 'java' |
| 31 | + sourceCompatibility = 1.7 |
| 32 | + targetCompatibility = 1.7 |
| 33 | +} |
| 34 | + |
| 35 | +dependencies { |
| 36 | + compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.+' |
| 37 | + testCompile group: 'junit', name: 'junit', version: '4.+' |
| 38 | +} |
| 39 | + |
| 40 | +findbugs { |
| 41 | + ignoreFailures = true |
| 42 | + // toolVersion = "2.0.1" |
| 43 | + sourceSets = [sourceSets.main] |
| 44 | + // reportsDir = file("$project.buildDir/reports/findbugs") |
| 45 | + effort = "min" |
| 46 | +} |
| 47 | + |
| 48 | +tasks.withType(FindBugs) { |
| 49 | + reportLevel = "high" // high |
| 50 | + reports { |
| 51 | + xml.enabled = false |
| 52 | + html.enabled = true |
| 53 | + } |
| 54 | + exclude { |
| 55 | + 'RE_POSSIBLE_UNINTENDED_PATTERN' |
| 56 | + 'DM_DEFAULT_ENCODING' |
| 57 | + } |
| 58 | +} |
| 59 | + |
| 60 | +bintray { |
| 61 | + user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : "" |
| 62 | + key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : "" |
| 63 | + // configurations = ['archives'] |
| 64 | + publications = ['mavenJava'] |
| 65 | + |
| 66 | + pkg { |
| 67 | + repo = 'databox' |
| 68 | + name = 'databox-sdk' |
| 69 | + userOrg = 'databox' |
| 70 | + licenses = ['MIT'] |
| 71 | + vcsUrl = 'https://github.com/databox/databox-java.git' |
| 72 | + version { |
| 73 | + name = '2.0' |
| 74 | + desc = 'Databox Java SDK' |
| 75 | + released = new Date() |
| 76 | + } |
| 77 | + } |
| 78 | +} |
| 79 | + |
| 80 | +task sourcesJar(type: Jar, dependsOn: classes) { |
| 81 | + classifier = 'sources' |
| 82 | + from sourceSets.main.allSource |
| 83 | +} |
| 84 | + |
| 85 | +task javadocJar(type: Jar, dependsOn: javadoc) { |
| 86 | + classifier = 'javadoc' |
| 87 | + from javadoc.destinationDir |
| 88 | +} |
| 89 | + |
| 90 | +artifacts { |
| 91 | + archives sourcesJar, javadocJar |
| 92 | +} |
| 93 | + |
| 94 | +def projectUrl = "https://github.com/databox/databox-java" |
| 95 | + |
| 96 | +publishing { |
| 97 | + publications { |
| 98 | + mavenJava(MavenPublication) { |
| 99 | + from components.java |
| 100 | + |
| 101 | + artifact sourcesJar { |
| 102 | + classifier "sources" |
| 103 | + } |
| 104 | + |
| 105 | + artifact javadocJar { |
| 106 | + classifier "javadoc" |
| 107 | + } |
| 108 | + |
| 109 | + pom.withXml { |
| 110 | + asNode().children().last() + { |
| 111 | + resolveStrategy = Closure.DELEGATE_FIRST |
| 112 | + name 'Databox Java SDK' |
| 113 | + description 'Java SDK for interacting with the Databox Push API.' |
| 114 | + url projectUrl |
| 115 | + scm { |
| 116 | + url projectUrl |
| 117 | + connection projectUrl |
| 118 | + developerConnection projectUrl |
| 119 | + } |
| 120 | + licenses { |
| 121 | + license { |
| 122 | + name 'The MIT License (MIT)' |
| 123 | + url 'http://rem.mit-license.org' |
| 124 | + distribution 'repo' |
| 125 | + } |
| 126 | + } |
| 127 | + developers { |
| 128 | + developer { |
| 129 | + id 'otobrglez' |
| 130 | + name 'Oto Brglez' |
| 131 | + |
| 132 | + } |
| 133 | + } |
| 134 | + } |
| 135 | + } |
| 136 | + } |
| 137 | + } |
| 138 | +} |
| 139 | + |
0 commit comments