Added Eclipse support for gradle
authorJeanderson Candido <jeandersonbc@gmail.com>
Mon, 2 Jul 2018 18:01:54 +0000 (15:01 -0300)
committerJeanderson Candido <jeandersonbc@gmail.com>
Mon, 2 Jul 2018 21:05:49 +0000 (18:05 -0300)
.gitignore
build.gradle

index 3b3685454c098c22b20f1e53136f69f780c6621e..9ccb9e27d48a9aa8939134985a2c2ca9fd23541a 100644 (file)
@@ -25,6 +25,7 @@ nbdist/
 .nb-gradle/
 
 ####### Covers Eclipse IDE #######
+.idea/
 .metadata
 tmp/
 *.tmp
@@ -34,8 +35,12 @@ tmp/
 .settings/
 .loadpath
 .recommenders
+.classpath
+.project
 
 ####### Covers JetBrains IDE: IntelliJ #######
+*.iml
+*.ipr
 
 # User-specific stuff:
 .idea/**/workspace.xml
index c2db9bc257ccfe0da29e0bf5fc4166d8ac92ac67..93714b1d3aefa749a81147a28cc944a55e70ea2c 100644 (file)
@@ -2,6 +2,7 @@ plugins {
     id "com.gradle.build-scan" version "1.14"
     id "java"
     id "jacoco"
+    id "eclipse"
 }
 
 sourceCompatibility = 1.8
@@ -11,7 +12,7 @@ ext.manifestCommonAttrbutes = manifest {
     attributes(
         "Built-By": System.getProperty("user.name"),
         "Implementation-Vendor": "NASA Ames Research Center",
-        "Implementation-Version": "1234" // FIXME
+        "Implementation-Version": "8.0"
     )
 }
 
@@ -365,4 +366,22 @@ test {
     }
 }
 
+eclipse {
+    group = "JPF IDE Support"
+
+    project {
+        natures = ["org.eclipse.buildship.core.gradleprojectnature"]
+    }
+    classpath {
+        defaultOutputDir = buildDir
+        file {
+            whenMerged { classpath ->
+                classpath.entries.findAll{ entry -> entry.kind == "src" }*.every { srcNode ->
+                    srcNode.output = srcNode.output.replace("bin", "${buildDir.name}")
+                }
+            }
+        }
+    }
+}
+
 defaultTasks "buildJars"