-
Notifications
You must be signed in to change notification settings - Fork 3
/
maven.gradle
80 lines (74 loc) · 2.04 KB
/
maven.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
apply plugin: 'maven'
apply plugin: 'maven-publish'
//apply plugin: 'signing'
//GITHOST: Remote hosting location e.g. GitHub.com, GitLab.com, BitBucket.org etc
//COMPANY: Company name or User
//REPOSITORY_NAME: Git Repository name
def group = "com.thesledgehammer" + "." + project.archivesBaseName
def semVersion = version_major + '.' + version_minor + '.' + version_patch
def artifactID = project.archivesBaseName + '_' + project.mcversion
jar {
classifier = 'universal'
manifest {
attributes 'FMLAT': project.archivesBaseName + '_at.cfg'
}
}
/*
signing {
if (project.hasProperty('keystore')) {
keyStore = System.getenv('keyStore')
alias = System.getenv('keyStoreAlias')
storePass = System.getenv('keyStorePass')
keyPass = System.getenv('keyStoreKeyPass')
inputFile = jar.archivePath
outputFile = jar.archivePath
}
}
*/
publishing {
publications {
maven(MavenPublication) {
groupId = group
version = semVersion
artifactId = artifactID
from components.java
pom {
scm {
connection = 'scm:git:git@' + GITHOST + ':' + COMPANY + '/' + REPOSITORY_NAME + '.git'
developerConnection = 'scm:git:git@' + GITHOST + ':' + COMPANY + '/' + REPOSITORY_NAME + '.git'
}
licenses {
license {
name = LICENSE_NAME
url = LICENSE_URL
distribution = 'repo'
}
}
developers {
developer {
id = 'TheSledgehammer'
name = 'TheSledgehammer'
}
}
}
}
}
repositories {
maven {
url "https://dl.bintray.com/thesledgehammer/development"
//url "file://${local_maven}"
}
}
}
bintray {
user = project.hasProperty('bintray_user') ? project.property('bintray_user') : System.getenv('bintray_user')
key = project.hasProperty('bintray_key') ? project.property('bintray_key') : System.getenv('bintray_key')
publications = ['maven']
pkg {
repo = 'development'
name = project.archivesBaseName
version {
name = semVersion
}
}
}