• R/O
  • HTTP
  • SSH
  • HTTPS

dictzip-java: Commit


Commit MetaInfo

Revisionc23c56a63653e05f698a0a26703567ec3b8a7a14 (tree)
Zeit2016-04-25 14:55:03
AutorHiroshi Miura <miurahr@linu...>
CommiterHiroshi Miura

Log Message

Release on Bintray

Signed-off-by: Hiroshi Miura <miurahr@linux.com>

Ändern Zusammenfassung

Diff

--- a/build.gradle
+++ b/build.gradle
@@ -11,6 +11,8 @@ subprojects {
1111 apply plugin: 'jacoco'
1212 apply plugin: 'checkstyle'
1313 apply plugin: 'findbugs'
14+ apply plugin: 'co.riiid.gradle'
15+ apply plugin: 'com.jfrog.bintray'
1416
1517 sourceCompatibility = jdkVersion
1618 targetCompatibility = jdkVersion
@@ -47,15 +49,50 @@ subprojects {
4749 test {
4850 useTestNG()
4951 }
52+
53+ task sourceJar(type: Jar) {
54+ from sourceSets.main.allSource
55+ classifier = 'sources'
56+ }
57+
58+ task javadocJar(type: Jar, dependsOn: javadoc) {
59+ description 'Generate jar file that have javadoc'
60+ classifier = 'javadoc'
61+ from javadoc.destinationDir
62+ }
63+
64+ artifacts {
65+ archives jar
66+ archives sourceJar
67+ archives javadocJar
68+ }
5069 }
5170
5271 group = projectGroup
53-version = projectVersion
5472
5573 project(':dictzip-lib') {
5674 dependencies {
5775 testCompile 'tokyo.northside:northside-io:0.2.0'
5876 }
77+ version = projectVersion
78+ bintray {
79+ user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER')
80+ key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : System.getenv('BINTRAY_API_KEY')
81+ configurations = ['archives']
82+ pkg {
83+ repo = 'maven'
84+ name = 'dictzip-lib'
85+ licenses = ['GPL-2.0+CE']
86+ vcsUrl = projectUrl
87+ labels = ['java','dictzip']
88+ publicDownloadNumbers = true
89+ version {
90+ name = projectVersion
91+ desc = projectDesc
92+ vcsTag = projectTag
93+ }
94+ }
95+ }
5996 }
6097
6198 project(':dictzip-cli') {
@@ -69,10 +106,28 @@ project(':dictzip-cli') {
69106 'gnu.getopt:java-getopt:1.0.13'
70107 testCompile 'tokyo.northside:northside-io:0.2.0'
71108 }
109+ version = projectVersion
110+ bintray {
111+ user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER')
112+ key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : System.getenv('BINTRAY_API_KEY')
113+ configurations = ['archives']
114+ pkg {
115+ repo = 'maven'
116+ name = 'dictzip-cli'
117+ licenses = ['GPL-3.0']
118+ vcsUrl = projectUrl
119+ labels = ['java','dictzip']
120+ publicDownloadNumbers = true
121+ version {
122+ name = projectVersion
123+ desc = projectDesc
124+ vcsTag = projectTag
125+ }
126+ }
127+ }
72128 }
73129
74-if (gradle.startParameter.taskNames.contains('uploadArchives') ||
75- gradle.startParameter.taskNames.contains('bintrayUpload') ||
76- gradle.startParameter.taskNames.contains('githubRelease)) {
130+if (gradle.startParameter.taskNames.contains('bintrayUpload') ||
131+ gradle.startParameter.taskNames.contains('githubRelease')) {
77132 apply from: 'build.publish.gradle'
78133 }
--- a/build.publish.gradle
+++ b/build.publish.gradle
@@ -1,4 +1,3 @@
1-apply plugin: 'maven'
21 apply plugin: 'signing'
32
43 boolean validProperty(propertyName) {
@@ -7,8 +6,6 @@ boolean validProperty(propertyName) {
76 }
87 assert validProperty('signing.keyId'), 'properties for signing must be provided'
98 assert validProperty('signing.secretKeyRingFile'), 'properties for signing must be provided'
10-assert validProperty('sonatypeUsername'), 'properties for publish must be provided'
11-assert validProperty('sonatypeFullname'), 'properties for publish must be provided'
129
1310 String askPassword(prompt) {
1411 "${System.console().readPassword(prompt)}"
@@ -19,25 +16,6 @@ signing {
1916 sign configurations.archives
2017 }
2118
22-bintray {
23- user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER')
24- key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : System.getenv('BINTRAY_API_KEY')
25- configurations = ['archives']
26- pkg {
27- repo = 'maven'
28- name = 'dictzip'
29- licenses = ['GPL-3']
30- vcsUrl = projectUrl
31- labels = ['java','dictzip']
32- publicDownloadNumbers = true
33- version {
34- name = projectVersion
35- desc = projectDesc
36- vcsTag = projectTag
37- }
38- }
39-}
40-
4119 github {
4220 owner = projectOwner
4321 repo = 'dictzip-java'
@@ -48,45 +26,7 @@ github {
4826 draft = true
4927 body = projectReleaseBody
5028 assets = [
51- 'build/libs/dictzip-cli.jar',
52- 'build/libs/dictzip-cli.jar.asc',
53- 'build/libs/dictzip-lib.jar',
54- 'build/libs/dictzip-lib.jar.asc',
55- 'build/libs/dictzip-javadoc.jar',
56- 'build/libs/dictzip-javadoc.jar.asc',
57- 'build/libs/dictzip-source.jar',
58- 'build/libs/dictzip-source.jar.asc'
29+ 'dictzip-cli/build/distributions/DictZip.zip',
30+ 'dictzip-lib/build/libs/dictzip-lib.jar'
5931 ]
6032 }
61-
62-uploadArchives {
63- repositories.mavenDeployer {
64- repository url: "file://$System.env.HOME/.m2/repository"
65- beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) }
66- pom.project {
67- name project.name
68- packaging 'jar'
69- description projectDesc
70- url projectUrl
71- version projectVersion
72- licenses {
73- license {
74- name 'GNU General Public License version 3.0 with classpath link exception.'
75- distribution 'repo'
76- }
77- }
78- scm {
79- url githubUrl
80- connection "scm:git:${githubUrl}"
81- developerConnection "scm:git:${githubUrl}"
82- }
83- developers {
84- developer {
85- id 'miurahr'
86- name 'Hiroshi Miura'
87- email 'miurahr@linux.com'
88- }
89- }
90- }
91- }
92-}
Show on old repository browser