Skip to content

Commit

Permalink
Convert thrifty-java-codegen to Kotlin (#173)
Browse files Browse the repository at this point in the history
As part of the prep work for implementing Kotlin codegen, we're converting the compiler to Kotlin. This is the first portion to be converted; thrifty-schema is next, in stages.
  • Loading branch information
benjamin-bader committed Jun 4, 2018
1 parent e1b1f70 commit 6d8187b
Show file tree
Hide file tree
Showing 23 changed files with 3,284 additions and 3,623 deletions.
7 changes: 7 additions & 0 deletions build.gradle
Expand Up @@ -28,6 +28,8 @@ allprojects {
version VERSION

project.ext {
kotlin_version = '1.2.41'

libraries = [
guava: [
'com.google.guava:guava:23.0'
Expand All @@ -41,6 +43,10 @@ allprojects {
'com.squareup:javapoet:1.11.1'
],

kotlin: [
"org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
],

testing: [
'junit:junit:4.12',
'org.mockito:mockito-core:1.10.19',
Expand All @@ -62,6 +68,7 @@ buildscript {

dependencies {
classpath 'net.ltgt.gradle:gradle-errorprone-plugin:0.0.14'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.2.41"
}
}

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
@@ -1,5 +1,5 @@
GROUP=com.microsoft.thrifty
VERSION=0.4.4-SNAPSHOT
VERSION=0.5.0-SNAPSHOT

POM_URL=https://github.com/microsoft/thrifty/

Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Expand Up @@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.3.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-4.7-all.zip
5 changes: 5 additions & 0 deletions thrifty-java-codegen/build.gradle
Expand Up @@ -18,6 +18,9 @@
*
* See the Apache Version 2.0 License for specific language governing permissions and limitations under the License.
*/

apply plugin: 'kotlin'

description = 'Converts Thrifty Schemas into Java source files'

dependencies {
Expand All @@ -26,6 +29,8 @@ dependencies {
api libraries.okio
api libraries.javaPoet

api libraries.kotlin

implementation project(':thrifty-runtime')

testImplementation libraries.testing
Expand Down

0 comments on commit 6d8187b

Please sign in to comment.