Skip to content

Commit

Permalink
Update build to Java17. Add GH actions build script. (#31)
Browse files Browse the repository at this point in the history
* Update gradle build to Java 17

* Add gh actions build. Fix line endings.
  • Loading branch information
ThatRedox authored Oct 31, 2022
1 parent 3580f75 commit 8184086
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 4 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/plugin_build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Plugin Build

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Setup JDK 17
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: '17'
java-package: jdk

- name: Grant executable permission for gradlew
run: chmod +x gradlew

- name: Build with Gradle
run: ./gradlew pluginJar

- name: Upload the plugin Jar
uses: actions/upload-artifact@v3
with:
name: ChunkyDenoiser
path: build/libs/*.jar
if-no-files-found: error
13 changes: 12 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,18 @@ These files can be used by [Intel Open Image Denoise][openimagedenoise-dl] like
./denoise -ldr scene-name.pfm -alb scene-name.albedo.pfm -nrm scene-name.normal.pfm -o output.pfm
```

## License
# Development

It is recommended to use [IntelliJ](https://www.jetbrains.com/idea/). Install the Java17 JDK ([Temurin](https://adoptium.net/) is the recommended distribution).
Then, [clone](https://www.jetbrains.com/help/idea/set-up-a-git-repository.html#clone-repo) the Chunky repository and let IntelliJ index the project.
Navigate to `src/main/java/de/lemaik/chunky/denoiser/DenoiserPlugin` and click the green play button next to `public class DenoiserPlugin implements Plugin {` to build and run the denoiser plugin.

To build the plugin externally, run the `gradlew` script in the project root directory. Gradle is setup with a few main tasks:

* `gradlew pluginJar` - Build the denoiser plugin Jar
* `gradlew clean` - Cleans the project. Removes old builds.

# License

Copyright 2019-2021 Maik Marschner (leMaik)

Expand Down
11 changes: 9 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
apply plugin: 'java'
plugins {
id 'org.openjfx.javafxplugin' version '0.0.10'
}
jar.enabled = false

sourceCompatibility = '1.8'
Expand Down Expand Up @@ -30,11 +32,16 @@ jar {
}
}

javafx {
version = '17'
modules = ['javafx.base', 'javafx.controls', 'javafx.fxml']
configuration = 'provided'
}

repositories {
mavenLocal()
mavenCentral()
maven {
url 'https://repo.lemaik.de/'
}
}

2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

0 comments on commit 8184086

Please sign in to comment.