From 96fbbd663431b10ea01f06d88e5f671204f28fd7 Mon Sep 17 00:00:00 2001 From: "Erik C. Thauvin" Date: Fri, 30 Sep 2022 22:31:47 -0700 Subject: [PATCH] Upgraded to Kotlin 1.7.20 --- .circleci/config.yml | 12 ++++++------ .github/workflows/gradle.yml | 2 +- README.md | 6 +++++- bitbucket-pipelines.yml | 2 +- build.gradle.kts | 8 ++++---- examples/build.gradle.kts | 6 +++--- 6 files changed, 20 insertions(+), 16 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index d753e7d..29685bf 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -30,19 +30,19 @@ defaults_gradle: &defaults_gradle path: build/reports/ jobs: - build_gradle_jdk17: + build_gradle_jdk18: <<: *defaults docker: - - image: cimg/openjdk:17.0 + - image: cimg/openjdk:18.0 <<: *defaults_gradle - build_gradle_jdk8: + build_gradle_jdk11: <<: *defaults docker: - - image: cimg/openjdk:8.0 + - image: cimg/openjdk:11.0 <<: *defaults_gradle @@ -50,5 +50,5 @@ workflows: version: 2 gradle: jobs: - - build_gradle_jdk8 - - build_gradle_jdk17 + - build_gradle_jdk11 + - build_gradle_jdk18 diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index 4a473de..a0b7843 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -12,7 +12,7 @@ jobs: strategy: matrix: - java-version: [ 1.8, 11, 17 ] + java-version: [ 11, 18 ] steps: - uses: actions/checkout@v2 diff --git a/README.md b/README.md index f9c650e..92f2534 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ [![License (3-Clause BSD)](https://img.shields.io/badge/license-BSD%203--Clause-blue.svg?style=flat-square)](https://opensource.org/licenses/BSD-3-Clause) [![Release](https://img.shields.io/github/release/ethauvin/readingtime.svg)](https://github.com/ethauvin/readingtime/releases/latest) [![Maven Central](https://img.shields.io/maven-central/v/net.thauvin.erik/readingtime.svg?label=maven%20central)](https://search.maven.org/search?q=g:%22net.thauvin.erik%22%20AND%20a:%22readingtime%22) -[![Known Vulnerabilities](https://snyk.io/test/github/ethauvin/readingtime/badge.svg?targetFile=pom.xml)](https://snyk.io/test/github/ethauvin/readingtime?targetFile=pom.xml) [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=ethauvin_readingtime&metric=alert_status)](https://sonarcloud.io/dashboard?id=ethauvin_readingtime) [![GitHub CI](https://github.com/ethauvin/readingtime/actions/workflows/gradle.yml/badge.svg)](https://github.com/ethauvin/readingtime/actions/workflows/gradle.yml) [![CircleCI](https://circleci.com/gh/ethauvin/readingtime/tree/master.svg?style=shield)](https://circleci.com/gh/ethauvin/readingtime/tree/master) +[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=ethauvin_readingtime&metric=alert_status)](https://sonarcloud.io/dashboard?id=ethauvin_readingtime) [![GitHub CI](https://github.com/ethauvin/readingtime/actions/workflows/gradle.yml/badge.svg)](https://github.com/ethauvin/readingtime/actions/workflows/gradle.yml) [![CircleCI](https://circleci.com/gh/ethauvin/readingtime/tree/master.svg?style=shield)](https://circleci.com/gh/ethauvin/readingtime/tree/master) # Estimated Reading Time for Blog Posts, Articles, etc. @@ -27,6 +27,10 @@ To get the estimated reading time in seconds use the `calcReadingTimeInSec()` fu To use with [Gradle](https://gradle.org/), include the following dependency in your [build](https://github.com/ethauvin/readingtime/blob/master/examples/build.gradle.kts) file: ```gradle +repositories { + mavenCentral() +} + dependencies { implementation("net.thauvin.erik:readingtime:0.9.1") } diff --git a/bitbucket-pipelines.yml b/bitbucket-pipelines.yml index 7d98402..a9514a0 100644 --- a/bitbucket-pipelines.yml +++ b/bitbucket-pipelines.yml @@ -1,4 +1,4 @@ -image: openjdk:8 +image: maven:3-openjdk-18 pipelines: default: diff --git a/build.gradle.kts b/build.gradle.kts index e0d44bf..80495a4 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -13,7 +13,7 @@ plugins { id("org.jetbrains.kotlinx.kover") version "0.6.0" id("org.sonarqube") version "3.4.0.2513" id("signing") - kotlin("jvm") version "1.7.10" + kotlin("jvm") version "1.7.20" } description = "Estimated Reading Time for Blog Posts, Articles, etc." @@ -41,8 +41,8 @@ dependencies { } java { - sourceCompatibility = JavaVersion.VERSION_1_8 - targetCompatibility = JavaVersion.VERSION_1_8 + sourceCompatibility = JavaVersion.VERSION_11 + targetCompatibility = JavaVersion.VERSION_11 withSourcesJar() } @@ -128,7 +128,7 @@ tasks { register("deploy") { description = "Copies all needed files to the $deployDir directory." group = PublishingPlugin.PUBLISH_TASK_GROUP - dependsOn(build, jar) + dependsOn(clean, wrapper, build, jar) outputs.dir(deployDir) inputs.files(copyToDeploy) mustRunAfter(clean) diff --git a/examples/build.gradle.kts b/examples/build.gradle.kts index 613de64..1b662f0 100644 --- a/examples/build.gradle.kts +++ b/examples/build.gradle.kts @@ -3,7 +3,7 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile plugins { id("application") id("com.github.ben-manes.versions") version "0.42.0" - kotlin("jvm") version "1.7.10" + kotlin("jvm") version "1.7.20" } // ./gradlew run @@ -19,8 +19,8 @@ dependencies { } java { - sourceCompatibility = JavaVersion.VERSION_1_8 - targetCompatibility = JavaVersion.VERSION_1_8 + sourceCompatibility = JavaVersion.VERSION_11 + targetCompatibility = JavaVersion.VERSION_11 } application {