Skip to content

Commit

Permalink
Migrate to Kotlin
Browse files Browse the repository at this point in the history
  • Loading branch information
vlsi committed Jul 22, 2020
1 parent 505055c commit 11a5c69
Show file tree
Hide file tree
Showing 10 changed files with 277 additions and 490 deletions.
13 changes: 12 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import org.gradle.api.tasks.wrapper.Wrapper.DistributionType
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile

plugins {
`maven-publish`
id("java-gradle-plugin")
`kotlin-dsl`
id("com.gradle.plugin-publish") version "0.9.7"
id("org.shipkit.java") version "2.3.4"
id("org.shipkit.gradle-plugin") version "2.3.4"
Expand All @@ -19,6 +20,16 @@ java {
targetCompatibility = JavaVersion.VERSION_1_7
}

tasks.configureEach<KotlinCompile> {
kotlinOptions {
jvmTarget = "1.6"
}
}

kotlinDslPluginOptions {
experimentalWarning.set(false)
}

dependencies {
implementation("com.amazonaws:aws-java-sdk-s3:1.11.751")

Expand Down
5 changes: 5 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
org.gradle.parallel=true
# See https://github.com/gradle/gradle/pull/11358 , https://issues.apache.org/jira/browse/INFRA-14923
# repository.apache.org does not yet support .sha256 and .sha512 checksums
systemProp.org.gradle.internal.publish.checksums.insecure=true
kotlin.parallel.tasks.in.project=true
105 changes: 0 additions & 105 deletions src/main/java/ch/myniva/gradle/caching/s3/AwsS3BuildCache.java

This file was deleted.

This file was deleted.

This file was deleted.

30 changes: 30 additions & 0 deletions src/main/kotlin/ch/myniva/gradle/caching/s3/AwsS3BuildCache.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
/*
* Copyright 2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package ch.myniva.gradle.caching.s3

import org.gradle.caching.configuration.AbstractBuildCache

open class AwsS3BuildCache : AbstractBuildCache() {
var region: String? = null
var bucket: String? = null
var path: String? = null
var isReducedRedundancy = true
var endpoint: String? = null
var headers: Map<String?, String?>? = null
var awsAccessKeyId: String? = null
var awsSecretKey: String? = null
var sessionToken: String? = null
}
Loading

0 comments on commit 11a5c69

Please sign in to comment.