Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to Kotlin 1.9.0 #307

Merged
merged 3 commits into from
Aug 10, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package com.xebia.functional.xef.env

import kotlinx.cinterop.ExperimentalForeignApi
import kotlinx.cinterop.toKString

@OptIn(ExperimentalForeignApi::class)
actual fun getenv(name: String): String? = platform.posix.getenv(name)?.toKString()
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.xebia.functional.xef.io


import kotlinx.cinterop.ExperimentalForeignApi
import kotlinx.cinterop.refTo
import kotlinx.cinterop.toKString
import platform.posix.*
Expand All @@ -13,6 +14,7 @@ object LinuxCommandExecutor : CommandExecutor {
/**
* https://stackoverflow.com/questions/57123836/kotlin-native-execute-command-and-get-the-output
*/
@OptIn(ExperimentalForeignApi::class)
override suspend fun executeCommandAndCaptureOutput(
command: List<String>,
options: ExecuteCommandOptions
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.xebia.functional.xef.io

import kotlinx.cinterop.ExperimentalForeignApi
import kotlinx.cinterop.refTo
import kotlinx.cinterop.toKString
import platform.posix.*
Expand All @@ -12,6 +13,7 @@ object MacosCommandExecutor : CommandExecutor {
/**
* https://stackoverflow.com/questions/57123836/kotlin-native-execute-command-and-get-the-output
*/
@OptIn(ExperimentalForeignApi::class)
override suspend fun executeCommandAndCaptureOutput(command: List<String>, options: ExecuteCommandOptions): String {
chdir(options.directory)
val commandToExecute = command.joinToString(separator = " ") { arg ->
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.xebia.functional.xef.io

import kotlinx.cinterop.ExperimentalForeignApi
import kotlinx.cinterop.refTo
import kotlinx.cinterop.toKString
import kotlinx.coroutines.runBlocking
Expand Down Expand Up @@ -50,6 +51,7 @@ object WindowsCommandExecutor : CommandExecutor {
/**
* https://stackoverflow.com/questions/57123836/kotlin-native-execute-command-and-get-the-output
*/
@OptIn(ExperimentalForeignApi::class)
override suspend fun executeCommandAndCaptureOutput(command: List<String>, options: ExecuteCommandOptions): String {
chdir(options.directory)
val commandToExecute = command.joinToString(separator = " ") { arg ->
Expand Down
4 changes: 3 additions & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[versions]
arrow = "1.2.0"
arrowGradle = "0.12.0-rc.5"
kotlin = "1.8.22"
kotlin = "1.9.0"
kotlinx-json = "1.5.1"
ktor = "2.3.2"
spotless = "6.20.0"
Expand Down Expand Up @@ -40,6 +40,7 @@ jsonschema = "4.31.1"
jakarta = "3.0.2"
suspend-transform = "0.3.1"
suspendApp = "0.4.0"
resources-kmp = "0.4.0"

[libraries]
arrow-core = { module = "io.arrow-kt:arrow-core", version.ref = "arrow" }
Expand Down Expand Up @@ -129,3 +130,4 @@ scala-multiversion = { id = "com.adtran.scala-multiversion-plugin", version.ref
kotest-multiplatform = { id = "io.kotest.multiplatform", version.ref = "kotest" }
semver-gradle = { id="com.javiersc.semver", version.ref="semverGradle" }
suspend-transform-plugin = { id="love.forte.plugin.suspend-transform", version.ref="suspend-transform" }
resources = { id="com.goncalossilva.resources", version.ref="resources-kmp" }
2 changes: 1 addition & 1 deletion tokenizer/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ plugins {
alias(libs.plugins.spotless)
alias(libs.plugins.arrow.gradle.publish)
alias(libs.plugins.semver.gradle)
id("com.goncalossilva.resources") version "0.3.2"
alias(libs.plugins.resources)
}

repositories {
Expand Down