-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
117 lines (97 loc) · 3.12 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
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
buildscript {
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath "org.jfrog.buildinfo:build-info-extractor-gradle:latest.release"
}
}
plugins {
id 'java'
}
apply plugin: 'maven-publish'
apply plugin: 'idea'
apply plugin: 'maven'
group 'co.chatchain'
version = System.getenv()['BUILD_NUMBER'] != null ? System.getenv()['BUILD_NUMBER'] : System.getenv()['TRAVIS_BUILD_NUMBER']
archivesBaseName = 'commons'
sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = 1.8
repositories {
mavenCentral()
}
dependencies {
testCompile group: 'junit', name: 'junit', version: '4.12'
compile('org.json:json:20160810')
compile('org.slf4j:slf4j-jdk14:1.7.25')
compile('com.microsoft.signalr:signalr:1.0.2')
compile('ninja.leaping.configurate:configurate-gson:3.3')
compile('com.google.inject:guice:4.1.0')
compile('com.intellij:annotations:+@jar')
}
idea {
module {
inheritOutputDirs = true
}
}
jar {
from sourceSets.main.output
manifest {
attributes([
'Maven-Artifact' : "${project.group}:${project.archivesBaseName}:${project.version}",
'Specification-Title' : "commons",
'Specification-Vendor' : "chatchain",
'Specification-Version' : "1",
'Implementation-Title' : project.name,
'Implementation-Version' : "${version}",
'Implementation-Vendor' : "chatchain",
'Implementation-Timestamp' : new Date().format("yyyy-MM-dd'T'HH:mm:ssZ")
])
}
}
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.allSource
}
artifacts {
archives sourcesJar
}
//Define what to publish and how.
publishing {
publications {
maven(MavenPublication) {
groupId = project.group
artifactId "commons"
artifact sourcesJar
from components.java
pom {
url = 'https://github.com/ldtteam/ChatChainCommons'
licenses {
license {
name = 'GNU GENERAL PUBLIC LICENSE Version 3'
url = 'https://www.gnu.org/licenses/gpl-3.0.en.html'
}
}
developers {
developer {
id = 'AshersLab'
name = 'Asher'
email = '[email protected]'
}
}
contributors {
contributor {
id = 'ldtteam'
name = 'Let\'s Develop Together - Team'
email = '[email protected]'
}
}
scm {
connection = 'scm:git:git://github.com/ldtteam/chatchaincommons.git'
developerConnection = 'scm:git:ssh://github.com/ldtteam/chatchaincommons.git'
url = 'https://github.com/ldtteam/ChatChainCommons'
}
}
}
}
}