mirror of
https://github.com/dmulloy2/ProtocolLib.git
synced 2024-11-23 19:16:14 +01:00
fix version and deploy
This commit is contained in:
parent
24204e7515
commit
71af32aa68
22
build.gradle
22
build.gradle
@ -8,11 +8,10 @@ group = 'com.comphenix.protocol'
|
|||||||
version = '5.0.0-SNAPSHOT'
|
version = '5.0.0-SNAPSHOT'
|
||||||
description = 'Provides access to the Minecraft protocol'
|
description = 'Provides access to the Minecraft protocol'
|
||||||
|
|
||||||
// java.sourceCompatibility = JavaVersion.VERSION_17
|
def isSnapshot = version.endsWith('-SNAPSHOT')
|
||||||
// java.targetCompatibility = JavaVersion.VERSION_17
|
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
// mavenLocal()
|
// mavenLocal() // can speed up build, but may fail in CI
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
|
|
||||||
maven {
|
maven {
|
||||||
@ -41,7 +40,6 @@ dependencies {
|
|||||||
compileOnly 'net.kyori:adventure-text-serializer-gson:4.13.0'
|
compileOnly 'net.kyori:adventure-text-serializer-gson:4.13.0'
|
||||||
compileOnly 'com.googlecode.json-simple:json-simple:1.1.1'
|
compileOnly 'com.googlecode.json-simple:json-simple:1.1.1'
|
||||||
|
|
||||||
// testImplementation 'org.junit.jupiter:junit-jupiter:5.9.2'
|
|
||||||
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.9.2'
|
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.9.2'
|
||||||
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.9.2'
|
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.9.2'
|
||||||
testImplementation 'org.mockito:mockito-core:4.11.0'
|
testImplementation 'org.mockito:mockito-core:4.11.0'
|
||||||
@ -72,13 +70,12 @@ test {
|
|||||||
}
|
}
|
||||||
|
|
||||||
processResources {
|
processResources {
|
||||||
def fullVersion = System.getenv('BUILD_NUMBER')
|
def includeBuild = isSnapshot && System.getenv('BUILD_NUMBER')
|
||||||
|
def fullVersion = includeBuild
|
||||||
? version + '-' + System.getenv('BUILD_NUMBER')
|
? version + '-' + System.getenv('BUILD_NUMBER')
|
||||||
: version
|
: version
|
||||||
|
|
||||||
filter {
|
eachFile { expand(['version': fullVersion]) }
|
||||||
it.replace('${project.version}', fullVersion)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
publishing {
|
publishing {
|
||||||
@ -90,13 +87,18 @@ publishing {
|
|||||||
artifactId = 'ProtocolLib'
|
artifactId = 'ProtocolLib'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
maven {
|
maven {
|
||||||
url = version.endsWith('SNAPSHOT')
|
url isSnapshot
|
||||||
? 'https://repo.dmulloy2.net/repository/snapshots/'
|
? 'https://repo.dmulloy2.net/repository/snapshots/'
|
||||||
: 'https://repo.dmulloy2.net/repository/releases/'
|
: 'https://repo.dmulloy2.net/repository/releases/'
|
||||||
|
|
||||||
|
credentials {
|
||||||
|
username project.nexusUsername
|
||||||
|
password project.nexusPassword
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
2
gradle.properties
Normal file
2
gradle.properties
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
nexusUsername=""
|
||||||
|
nexusPassword=""
|
@ -1,5 +1,5 @@
|
|||||||
name: ProtocolLib
|
name: ProtocolLib
|
||||||
version: ${project.fullVersion}
|
version: ${version}
|
||||||
description: Provides read/write access to the Minecraft protocol.
|
description: Provides read/write access to the Minecraft protocol.
|
||||||
authors: [dmulloy2, comphenix]
|
authors: [dmulloy2, comphenix]
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user