diff --git a/gradle.properties b/gradle.properties index 9759e31..b3148b3 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1 +1 @@ -version=0.0.1 \ No newline at end of file +version=1.74-0.1 diff --git a/imgui-binding/build.gradle b/imgui-binding/build.gradle index 137166c..d828568 100644 --- a/imgui-binding/build.gradle +++ b/imgui-binding/build.gradle @@ -2,9 +2,46 @@ import imgui.generate.GenerateLibs plugins { id 'java' + id 'com.jfrog.bintray' version '1.8.4' + id 'maven-publish' } sourceCompatibility = 1.8 assemble.dependsOn clean task generateLibs(type: GenerateLibs, dependsOn: assemble) + +task sourcesJar(type: Jar, dependsOn: classes) { + archiveClassifier.set('sources') + from sourceSets.main.allSource +} + +publishing { + publications { + MyPublication(MavenPublication) { + from components.java + artifact sourcesJar + groupId 'imgui-java' + artifactId 'binding' + version property('version') + } + } +} + +bintray { + user = System.getenv('BINTRAY_USER') + key = System.getenv('BINTRAY_API_KEY') + publications = ['MyPublication'] + override = true + pkg { + repo = 'imgui-java' + name = 'binding' + userOrg = user + desc = 'A handcrafted 1-1 Java binding for the Dear-ImGui' + licenses = ['Apache-2.0'] + vcsUrl = 'https://github.com/SpaiR/imgui-java' + labels = ['dear-imgui', 'java', 'jni'] + githubRepo = 'SpaiR/imgui-java' + publicDownloadNumbers = true + } +} diff --git a/imgui-lwjgl3/build.gradle b/imgui-lwjgl3/build.gradle index e68c0f8..191ca81 100644 --- a/imgui-lwjgl3/build.gradle +++ b/imgui-lwjgl3/build.gradle @@ -1,8 +1,8 @@ -import org.gradle.internal.os.OperatingSystem - plugins { id 'java' id 'checkstyle' + id 'com.jfrog.bintray' version '1.8.4' + id 'maven-publish' } sourceCompatibility = 1.8 @@ -11,24 +11,49 @@ ext { lwjglVersion = '3.2.3' } -switch (OperatingSystem.current()) { - case OperatingSystem.LINUX: - project.ext.lwjglNatives = 'natives-linux' - break - case OperatingSystem.WINDOWS: - project.ext.lwjglNatives = System.getProperty('os.arch').contains('64') ? 'natives-windows' : 'natives-windows-x86' - break -} - dependencies { implementation platform("org.lwjgl:lwjgl-bom:$lwjglVersion") implementation 'org.lwjgl:lwjgl' implementation 'org.lwjgl:lwjgl-glfw' implementation 'org.lwjgl:lwjgl-opengl' - runtimeOnly "org.lwjgl:lwjgl::$lwjglNatives" - runtimeOnly "org.lwjgl:lwjgl-glfw::$lwjglNatives" - runtimeOnly "org.lwjgl:lwjgl-opengl::$lwjglNatives" implementation project(':imgui-binding') } + + + +task sourcesJar(type: Jar, dependsOn: classes) { + archiveClassifier.set('sources') + from sourceSets.main.allSource +} + +publishing { + publications { + MyPublication(MavenPublication) { + from components.java + groupId 'imgui-java' + artifact sourcesJar + artifactId 'lwjgl3' + version property('version') + } + } +} + +bintray { + user = System.getenv('BINTRAY_USER') + key = System.getenv('BINTRAY_API_KEY') + publications = ['MyPublication'] + override = true + pkg { + repo = 'imgui-java' + name = 'lwjgl3' + userOrg = user + desc = 'Backend implementation for imgui-java based on LWJGL3' + licenses = ['Apache-2.0'] + vcsUrl = 'https://github.com/SpaiR/imgui-java' + labels = ['dear-imgui', 'java', 'lwjgl3'] + githubRepo = 'SpaiR/imgui-java' + publicDownloadNumbers = true + } +} diff --git a/imgui-lwjgl3/lwjgl-libs/glfw.dll b/imgui-lwjgl3/lwjgl-libs/glfw.dll new file mode 100644 index 0000000..0fbec1f Binary files /dev/null and b/imgui-lwjgl3/lwjgl-libs/glfw.dll differ diff --git a/imgui-lwjgl3/lwjgl-libs/lwjgl.dll b/imgui-lwjgl3/lwjgl-libs/lwjgl.dll new file mode 100644 index 0000000..055b4df Binary files /dev/null and b/imgui-lwjgl3/lwjgl-libs/lwjgl.dll differ diff --git a/imgui-lwjgl3/lwjgl-libs/lwjgl_opengl.dll b/imgui-lwjgl3/lwjgl-libs/lwjgl_opengl.dll new file mode 100644 index 0000000..ab29f88 Binary files /dev/null and b/imgui-lwjgl3/lwjgl-libs/lwjgl_opengl.dll differ