Example ZenCode scripting engine.
Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

build.gradle 1.2KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. apply plugin: 'java'
  2. sourceCompatibility = '1.8'
  3. [compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
  4. // NetBeans will automatically add "run" and "debug" tasks relying on the
  5. // "mainClass" property. You may however define the property prior executing
  6. // tasks by passing a "-PmainClass=<QUALIFIED_CLASS_NAME>" argument.
  7. //
  8. // Note however, that you may define your own "run" and "debug" task if you
  9. // prefer. In this case NetBeans will not add these tasks but you may rely on
  10. // your own implementation.
  11. if (!hasProperty('mainClass')) {
  12. ext.mainClass = ''
  13. }
  14. repositories {
  15. mavenCentral()
  16. maven { url "http://maven.openzen.org/" }
  17. }
  18. dependencies {
  19. compile 'org.openzen.zencode:zencode-javascripting:0.1.2'
  20. }
  21. task fatJar(type: Jar) {
  22. manifest {
  23. attributes 'Implementation-Title': 'ZenCode Java Scripting Engine Example',
  24. 'Class-Path': '.',
  25. 'Main-Class': 'org.openzen.javascriptingexample.Main'
  26. }
  27. baseName = project.name + '-all'
  28. from {
  29. configurations.compile.collect {
  30. it.isDirectory() ? it : zipTree(it)
  31. }
  32. } {
  33. exclude "META-INF/INDEX.LIST"
  34. exclude "META-INF/*.SF"
  35. exclude "META-INF/*.DSA"
  36. exclude "META-INF/*.RSA"
  37. }
  38. with jar
  39. }