Skip to content

Instantly share code, notes, and snippets.

@durganmcbroom
Created May 20, 2021 16:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save durganmcbroom/c1d9f72e27df269caf5a1943af4c1674 to your computer and use it in GitHub Desktop.
Save durganmcbroom/c1d9f72e27df269caf5a1943af4c1674 to your computer and use it in GitHub Desktop.
plugins {
id 'java'
id 'java-library'
id 'org.jetbrains.kotlin.jvm' version '1.5.0'
}
group 'com.example' //Not my actual group ID
version '1.0-SNAPSHOT'
test {
useJUnit()
}
java {
modularity.inferModulePath = true
}
tasks.named('compileJava') {
modularity.inferModulePath = true
options.javaModuleVersion = provider { project.version }
}
dependencies {
compile 'org.jetbrains:annotations:20.1.0'
compile 'org.ow2.asm:asm:9.1'
compile 'org.ow2.asm:asm-util:9.1'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.6.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine'
}
subprojects {
apply plugin: 'kotlin'
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
}
sourceCompatibility = 1.11
targetCompatibility = 1.11
compileKotlin {
kotlinOptions.jvmTarget = "1.11"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.11"
}
}
rootProject.name = 'mixin-utils'
include 'base.test'
//subProject('base.test') //Uncommenting to provide a path to the project directory
private String[] subProject(String... names) {
for (int i = 0; i < names.length; i++) {
project(names[i]).projectDir = new File("${rootDir.absolutePath}${File.separator}src${File.separator}${names[i]}")
}
return names
}
src
module1 (setup as a IJ module)
kotlin (setup as IJ sources)
example.packages
module-info.java
module2 (setup as a IJ module)
kotlin (setup as IJ sources)
example.packages
module-info.java
settings.gradle
build.gradle
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment