Skip to content

Commit 438d1bc

Browse files
committed
Add maven pom for github dependency tracking
1 parent c2d9371 commit 438d1bc

File tree

2 files changed

+40
-18
lines changed

2 files changed

+40
-18
lines changed

build.gradle

+18-18
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,14 @@ plugins {
55
id 'com.github.johnrengelman.shadow' version '6.1.0'
66
id 'java'
77
id 'application'
8+
id 'maven-publish'
89
}
910

1011
repositories {
1112
mavenCentral()
1213
}
1314

1415

15-
1616
group = "com.superzanti.serversync"
1717
version = ssversion
1818

@@ -94,23 +94,23 @@ task createServerExe(type: Launch4jLibraryTask) {
9494
version = ssversion
9595
}
9696

97-
//publishing {
98-
// repositories {
99-
// maven {
100-
// name = "GitHubPackages"
101-
// url = uri("https://maven.pkg.github.com/${System.getenv('GPR_REPO')}")
102-
// credentials {
103-
// username = project.findProperty("gpr.user") as String ?: System.getenv("GPR_USERNAME")
104-
// password = project.findProperty("gpr.key") as String ?: System.getenv("GPR_TOKEN")
105-
// }
106-
// }
107-
// }
108-
// publications {
109-
// shadow(MavenPublication) { publication ->
110-
// project.shadow.component(publication)
111-
// }
112-
// }
113-
//}
97+
publishing {
98+
repositories {
99+
maven {
100+
name = "GitHubPackages"
101+
url = uri("https://maven.pkg.github.com/${System.getenv('GPR_REPO')}")
102+
credentials {
103+
username = project.findProperty("gpr.user") as String ?: System.getenv("GPR_USERNAME")
104+
password = project.findProperty("gpr.key") as String ?: System.getenv("GPR_TOKEN")
105+
}
106+
}
107+
}
108+
publications {
109+
shadow(MavenPublication) { publication ->
110+
project.shadow.component(publication)
111+
}
112+
}
113+
}
114114

115115
clean {
116116
}

pom.xml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
3+
<modelVersion>4.0.0</modelVersion>
4+
<groupId>com.superzanti.serversync</groupId>
5+
<artifactId>ServerSync</artifactId>
6+
<version>4.2.0</version>
7+
<packaging>pom</packaging>
8+
<dependencies>
9+
<dependency>
10+
<groupId>com.eclipsesource.minimal-json</groupId>
11+
<artifactId>minimal-json</artifactId>
12+
<version>0.9.5</version>
13+
<scope>runtime</scope>
14+
</dependency>
15+
<dependency>
16+
<groupId>info.picocli</groupId>
17+
<artifactId>picocli</artifactId>
18+
<version>4.6.2</version>
19+
<scope>runtime</scope>
20+
</dependency>
21+
</dependencies>
22+
</project>

0 commit comments

Comments
 (0)