-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Re-implement in Kotlin Also - restructure package - better sanitize filename - use proper webmvc test - cleanup slices - fix code-styles
- Loading branch information
1 parent
db63d6a
commit 865a550
Showing
28 changed files
with
511 additions
and
475 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
configurations { | ||
compileOnly { | ||
// If we enable this, we will rebuild the entire project everytime we change anything, not compile cache | ||
extendsFrom annotationProcessor | ||
} | ||
developmentOnly {} | ||
runtimeClasspath { | ||
extendsFrom developmentOnly | ||
} | ||
|
||
// needed to get lombok working in our tests | ||
testImplementation { | ||
extendsFrom testAnnotationProcessor | ||
// we do not need junit5 asserts / integrations, remove for more auto include convenience | ||
exclude module: 'junit' | ||
// exclude hamcrest so we do not mix assertThat with assertj - we only use assertj | ||
// exclude group: 'org.hamcrest', module: 'hamcrest-library' | ||
// exclude group: 'org.hamcrest', module: 'hamcrest-core' | ||
} | ||
|
||
// Exclude Springs default logging framework since we use Log4j2g | ||
all*.exclude module : 'spring-boot-starter-logging' | ||
all*.exclude module : 'logback-classic' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
|
||
// @see https://github.com/sbrannen/spring-events/blob/master/build.gradle#L38 | ||
// and @see https://stackoverflow.com/a/54605523/3625317 | ||
dependencies { | ||
implementation( | ||
"org.jodconverter:jodconverter-local:$jodconverterVersion", | ||
"org.jodconverter:jodconverter-spring-boot-starter:$jodconverterVersion", | ||
"org.springframework.boot:spring-boot-starter-web", | ||
"org.springframework:spring-core", | ||
"commons-io:commons-io:$commonsIo", | ||
|
||
// needed when compiling against > Java 8 since jaxb is no longer included | ||
// you would get Error creating bean with name 'xmlModelPlugin': Lookup method resolution failed | ||
"org.glassfish.jaxb:jaxb-runtime:$jaxb", | ||
|
||
"org.jetbrains.kotlin:kotlin-reflect", | ||
"org.jetbrains.kotlin:kotlin-stdlib-jdk8", | ||
'org.apache.logging.log4j:log4j-api-kotlin:1.2.0' | ||
) | ||
|
||
testImplementation( | ||
"org.springframework.boot:spring-boot-starter-test", | ||
"org.junit.jupiter:junit-jupiter-api", | ||
"org.junit.jupiter:junit-jupiter-params", | ||
"org.mockito:mockito-core:$mockitoVersion", | ||
"org.mockito:mockito-junit-jupiter:$mockitoVersion", | ||
"org.apache.tika:tika-core:${tikaVersion}", | ||
"org.apache.tika:tika-parsers:${tikaVersion}", | ||
) | ||
|
||
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine") | ||
|
||
annotationProcessor( | ||
"javax.annotation:javax.annotation-api:$javaxAnnotations", | ||
"org.projectlombok:lombok:$lombokVersion" | ||
) | ||
|
||
testAnnotationProcessor( | ||
"org.projectlombok:lombok:$lombokVersion", | ||
) | ||
|
||
compileOnly( | ||
"org.projectlombok:lombok:$lombokVersion", | ||
"org.springframework.boot:spring-boot-configuration-processor" | ||
) | ||
|
||
developmentOnly("org.springframework.boot:spring-boot-devtools") | ||
|
||
runtimeOnly 'org.springframework.boot:spring-boot-starter-tomcat' | ||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
kotlin { | ||
// see https://docs.gradle.org/current/userguide/toolchains.html | ||
jvmToolchain { | ||
languageVersion.set(JavaLanguageVersion.of(17)) | ||
} | ||
} | ||
|
||
compileKotlin { | ||
compilerOptions { | ||
freeCompilerArgs = ["-Xjsr305=strict"] | ||
} | ||
} | ||
|
||
compileTestKotlin { | ||
compilerOptions { | ||
freeCompilerArgs = ["-Xjsr305=strict"] | ||
} | ||
} | ||
|
12 changes: 0 additions & 12 deletions
12
src/main/java/de/kontextwork/converter/ConverterApplication.java
This file was deleted.
Oops, something went wrong.
56 changes: 0 additions & 56 deletions
56
src/main/java/de/kontextwork/converter/service/ConverterService.java
This file was deleted.
Oops, something went wrong.
33 changes: 0 additions & 33 deletions
33
src/main/java/de/kontextwork/converter/service/api/UnknownSourceFormat.java
This file was deleted.
Oops, something went wrong.
66 changes: 0 additions & 66 deletions
66
src/main/java/de/kontextwork/converter/web/ConversionController.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.