Skip to content

Commit

Permalink
Modularize project (PR #18 from segunfamisa/master)
Browse files Browse the repository at this point in the history
This commit extracts existing code into two modules:
1. `floorplan-cli`
2. `core`

This will be useful for reusability and make implementing the Gradle plugin easier to implement - #15
  • Loading branch information
julioz authored May 13, 2020
2 parents b30f60a + a35bf9b commit 8d7a388
Show file tree
Hide file tree
Showing 25 changed files with 61 additions and 28 deletions.
28 changes: 1 addition & 27 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,37 +1,11 @@
plugins {
id 'application'
id 'java'
id 'org.jetbrains.kotlin.jvm' version '1.3.71'
id 'org.jetbrains.kotlin.plugin.serialization' version '1.3.71'
}

ext {
javaMainClass = "com.zynger.floorplan.AppKt"
id 'org.jetbrains.kotlin.jvm' version '1.3.71' apply false
}

group 'zynger'
version '0.1-SNAPSHOT'

sourceCompatibility = 1.8

repositories {
mavenCentral()
jcenter()
}

application {
mainClassName = javaMainClass
}

dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime:0.20.0" // JVM dependency
testCompile group: 'junit', name: 'junit', version: '4.12'
}

compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
25 changes: 25 additions & 0 deletions core/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm'
id 'org.jetbrains.kotlin.plugin.serialization' version '1.3.71'
}

sourceCompatibility = 1.8

repositories {
mavenCentral()
jcenter()
}

dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime:0.20.0" // JVM dependency
testImplementation "junit:junit:4.12"
}

compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
33 changes: 33 additions & 0 deletions floorplan-cli/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
plugins {
id 'application'
id 'java'
id 'org.jetbrains.kotlin.jvm'
}

group 'zynger'
version '0.1-SNAPSHOT'

sourceCompatibility = 1.8

repositories {
mavenCentral()
jcenter()
}

application {
mainClassName = "com.zynger.floorplan.AppKt"
}

dependencies {
implementation project(":core")
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
implementation "org.jetbrains.kotlinx:kotlinx-serialization-runtime:0.20.0" // JVM dependency
testImplementation "junit:junit:4.12"
}

compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
File renamed without changes.
3 changes: 2 additions & 1 deletion settings.gradle
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
rootProject.name = 'floorplan'

include 'core'
include 'floorplan-cli'

0 comments on commit 8d7a388

Please sign in to comment.