Skip to content

Commit b0e7c6c

Browse files
committed
Switch from publishdata to the standard publishing style
1 parent 31775a9 commit b0e7c6c

File tree

1 file changed

+9
-19
lines changed

1 file changed

+9
-19
lines changed

build.gradle.kts

Lines changed: 9 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,10 @@ plugins {
33
`java-library`
44
`maven-publish`
55
jacoco
6-
alias(libs.plugins.publishdata)
76
}
87

98
group = "net.theevilreaper"
10-
version = "1.11.1"
9+
version = "1.11.2"
1110
description = "Aves"
1211

1312
java {
@@ -60,34 +59,25 @@ tasks {
6059
}
6160
}
6261

63-
publishData {
64-
addMainRepo("https://repo.onelitefeather.dev/onelitefeather-releases")
65-
addMasterRepo("https://repo.onelitefeather.dev/onelitefeather-releases")
66-
addSnapshotRepo("https://repo.onelitefeather.dev/onelitefeather-snapshots")
67-
publishTask("jar")
68-
}
69-
7062
publishing {
71-
publications {
72-
create<MavenPublication>("maven") {
73-
// configure the publication as defined previously.
74-
publishData.configurePublication(this)
75-
version = publishData.getVersion(false)
76-
}
63+
publications.create<MavenPublication>("maven") {
64+
from(components["java"])
7765
}
66+
7867
repositories {
7968
maven {
8069
authentication {
8170
credentials(PasswordCredentials::class) {
82-
// Those credentials need to be set under "Settings -> Secrets -> Actions" in your repository
8371
username = System.getenv("ONELITEFEATHER_MAVEN_USERNAME")
8472
password = System.getenv("ONELITEFEATHER_MAVEN_PASSWORD")
8573
}
8674
}
87-
8875
name = "OneLiteFeatherRepository"
89-
// Get the detected repository from the publish data
90-
url = uri(publishData.getRepository())
76+
url = if (project.version.toString().contains("SNAPSHOT")) {
77+
uri("https://repo.onelitefeather.dev/onelitefeather-snapshots")
78+
} else {
79+
uri("https://repo.onelitefeather.dev/onelitefeather-releases")
80+
}
9181
}
9282
}
9383
}

0 commit comments

Comments
 (0)