# HG changeset patch # User riono # Date 1580373262 -32400 # Node ID 8e507ce09187817071fd2b9da4c42fbc2014c66a # Parent 07bc0bf4b21abd76e0eb51ed2ee25c8e0c484cc9 update build.gradle diff -r 07bc0bf4b21a -r 8e507ce09187 build.gradle --- a/build.gradle Thu Jan 30 17:26:01 2020 +0900 +++ b/build.gradle Thu Jan 30 17:34:22 2020 +0900 @@ -1,11 +1,10 @@ plugins { - id "edu.sc.seis.macAppBundle" version "2.3.0" + id 'application' } apply plugin:'java' apply plugin: 'eclipse' apply plugin: 'application' -apply plugin: "edu.sc.seis.macAppBundle" sourceCompatibility = JavaVersion.VERSION_11 @@ -16,20 +15,13 @@ def buildNo = processBuildNo(version) defaultTasks 'clean' , 'jar' -macAppBundle { + +application { mainClassName = "com.glavsoft.viewer.TreeViewer" - icon = "src/viewer_swing/resources/TreeVNC.png.icns" - bundleJRE = true - javaProperties.put("apple.laf.useScreenMenuBar", "true") } - -//convasion jar file for .app -//https://github.com/crotwell/gradle-macappbundle/wiki/Intro -//icon create web applecation -//https://iconverticons.com/online/ + configurations { viewerSwingImplementation { extendsFrom implementation } - //viewerSwingRuntime { extendsFrom viewerSwingCompile, runtime } } sourceSets { @@ -56,8 +48,7 @@ dependencies { viewerSwingImplementation group: 'com.jcraft', name: 'jsch', version: '0.1.+', ext: 'jar' implementation group: 'com.jcraft', name: 'jsch', version: '0.1.+', ext: 'jar' - //viewerSwingRuntime configurations.viewerSwingCompile -} + } def manifestAttributes = ['Main-Class': 'com.glavsoft.viewer.TreeViewer', 'Implementation-Version': "${project.version} (${buildNo})", @@ -65,45 +56,20 @@ 'Implementation-Vendor': 'GlavSoft LLC.'] jar { - //baseName = project.baseName - //version = null manifest { attributes manifestAttributes } -// def runtimeDeps = configurations.viewerSwingRuntime.collect { -// it.isDirectory() ? it : zipTree(it) -// } -// from(runtimeDeps) { -// exclude 'META-INF/**' -// } } - task noSshJar (type: Jar, dependsOn: classes) { -// baseName = 'nossh/' + project.baseName -// version = null manifest { attributes manifestAttributes } from sourceSets.main.output } -//artifacts { -// archives file('src/web/viewer-applet-example.html') -// archives noSshJar -//} - -//uploadArchives { -// repositories { -// -// } -// uploadDescriptor = false -//} - -//task dist(dependsOn: uploadArchives) - def processBuildNo(currentVersion) { final String VERSION = 'version' final String BUILD = 'build' @@ -149,11 +115,3 @@ // set mainclass to Application Plugin mainClassName = 'com.glavsoft.viewer.TreeViewer' applicationName = 'TreeVNC' - -//allprojects { -// gradle.projectsEvaluated { -// tasks.withType(JavaCompile) { -// options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation" -// } -// } -//}