Skip to content
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
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
[![](https://jitpack.io/v/adamko-dev/kotlinx-serialization-typescript-generator.svg)](https://jitpack.io/#adamko-dev/kotlinx-serialization-typescript-generator)
[![Status](https://img.shields.io/badge/status-proof--of--concept-blueviolet?style=flat-square)](https://github.com/adamko-dev/kotlinx-serialization-typescript-generator#status)
[![GitHub license](https://img.shields.io/github/license/adamko-dev/kotlinx-serialization-typescript-generator?style=flat-square)](https://github.com/adamko-dev/kotlinx-serialization-typescript-generator/blob/main/LICENSE)
[![Maven Central](https://img.shields.io/maven-central/v/dev.adamko.txstsgen/kxs-ts-gen-core?style=flat-square)](https://search.maven.org/search?q=g:dev.adamko.txstsgen)
[![](https://jitpack.io/v/adamko-dev/kotlinx-serialization-typescript-generator.svg?style=flat-square)](https://jitpack.io/#adamko-dev/kotlinx-serialization-typescript-generator)

# Kotlinx Serialization TypeScript Generator

Expand Down Expand Up @@ -35,7 +38,7 @@ export interface MyClass {
}
```

Only Kotlinx Serialization
Only Kotlinx Serialization
[`SerialDescriptor`s](https://kotlin.github.io/kotlinx.serialization/kotlinx-serialization-core/kotlinx.serialization.descriptors/-serial-descriptor/index.html)
are used to generate TypeScript. They are flexible and comprehensive enough to allow for accurate TypeScript code, without any deviation.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,14 @@ plugins {
signing
}

val sonatypeRepositoryCredentials: Provider<Action<PasswordCredentials>> = providers
.credentials(PasswordCredentials::class, "sonatypeRepository")
.map { credentials ->
val sonatypeRepositoryCredentials: Provider<Action<PasswordCredentials>> =
providers.zip(
providers.gradleProperty("sonatypeRepositoryUsername"),
providers.gradleProperty("sonatypeRepositoryPassword"),
) { user, pass ->
Action<PasswordCredentials> {
username = credentials.username
password = credentials.password
username = user
password = pass
}
}

Expand Down Expand Up @@ -60,6 +62,13 @@ tasks.matching {
}


// Gradle warns about some signing tasks using publishing task outputs without explicit
// dependencies. I'm not going to go through them all and fix them, so here's a quick safety check.
tasks.matching { it.name.startsWith("publish") }.configureEach {
mustRunAfter(tasks.matching { it.name.startsWith("sign") })
}


publishing {
if (sonatypeRepositoryCredentials.isPresent()) {
repositories {
Expand Down
3 changes: 1 addition & 2 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@ classgraph = "4.8.143"

gradleNodePlugin = "3.3.0"

#qoomonGitVersioning = "6.1.1" // bugged: https://github.com/qoomon/gradle-git-versioning-plugin/issues/76
qoomonGitVersioning = "5.2.0"
qoomonGitVersioning = "6.1.2"

[libraries]

Expand Down