Skip to content

Commit f1090c3

Browse files
authored
Publishing
Build Updates: * Update Root Project build.gradle - remove unused Kotlin plugin, update publishing target * Update settings.gradle - remove unused Kotlin plugin Workflows: * Create publish_release.yml
1 parent b61ee90 commit f1090c3

File tree

3 files changed

+48
-8
lines changed

3 files changed

+48
-8
lines changed
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# Create and Publish repository Packages
2+
3+
name: Publish Packages for Release
4+
5+
on:
6+
release:
7+
types: [ created ]
8+
9+
jobs:
10+
publish:
11+
runs-on: ubuntu-latest
12+
permissions:
13+
contents: read
14+
packages: write
15+
16+
name: Publish Release
17+
steps:
18+
- uses: actions/checkout@v3
19+
- uses: actions/setup-java@v3
20+
with:
21+
java-version: 17
22+
distribution: 'temurin'
23+
cache: 'gradle'
24+
25+
- name: Check Build
26+
run: ./gradlew assemble --warn
27+
timeout-minutes: 6
28+
29+
- name: Generate JavaDoc
30+
run: ./gradlew javadoc --warn
31+
if: success()
32+
timeout-minutes: 3
33+
34+
- name: Publish Packages
35+
run: ./gradlew publish --warn
36+
if: success()
37+
env:
38+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
39+
40+
- name: Upload JavaDoc
41+
uses: actions/upload-artifact@v3
42+
if: success() || failure()
43+
with:
44+
name: Files-JavaDocs
45+
path: /home/runner/work/*/*/*/build/docs/javadoc
46+
retention-days: 28
47+
timeout-minutes: 2

build.gradle

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ buildscript {
44
google()
55
}
66
dependencies {
7-
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.20")
87
}
98
}
109

@@ -13,11 +12,6 @@ allprojects {
1312
mavenCentral()
1413
google()
1514
}
16-
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
17-
kotlinOptions {
18-
jvmTarget = "17"
19-
}
20-
}
2115
}
2216

2317
subprojects {
@@ -26,7 +20,7 @@ subprojects {
2620
repositories {
2721
maven {
2822
name = "GitHubPackages"
29-
url = uri("https://maven.pkg.github.com/dk96-os/java-project")
23+
url = uri("https://maven.pkg.github.com/dk96-os/files-jvm")
3024
credentials {
3125
username = System.getenv("GITHUB_ACTOR")
3226
password = System.getenv("GITHUB_TOKEN")

settings.gradle

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
pluginManagement {
22
plugins {
3-
id "org.jetbrains.kotlin.jvm" version "1.9.20"
43
}
54
repositories {
65
google()

0 commit comments

Comments
 (0)