Update dokka, update resource extractor, update js wrapper versions, remove js from sample as gradle cant find libs when building
This commit is contained in:
parent
d9a847d39d
commit
d6945979a9
@ -20,11 +20,8 @@ buildscript {
|
|||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
google()
|
google()
|
||||||
maven ("https://kotlin.bintray.com/kotlinx")
|
|
||||||
maven ("https://dl.bintray.com/kotlin/kotlin-eap")
|
|
||||||
maven ("https://dl.bintray.com/kotlin/kotlin-dev")
|
|
||||||
gradlePluginPortal()
|
gradlePluginPortal()
|
||||||
jcenter()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
@ -39,10 +36,6 @@ allprojects {
|
|||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
google()
|
google()
|
||||||
maven ("https://kotlin.bintray.com/kotlinx")
|
|
||||||
maven ("https://dl.bintray.com/kotlin/kotlin-eap")
|
|
||||||
maven ("https://dl.bintray.com/kotlin/kotlin-dev")
|
|
||||||
jcenter()
|
|
||||||
maven {
|
maven {
|
||||||
url = uri("https://oss.sonatype.org/content/repositories/snapshots")
|
url = uri("https://oss.sonatype.org/content/repositories/snapshots")
|
||||||
}
|
}
|
||||||
|
@ -24,9 +24,6 @@ plugins {
|
|||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
maven ("https://dl.bintray.com/kotlin/kotlin-eap")
|
|
||||||
maven("https://dl.bintray.com/kotlin/kotlin-dev")
|
|
||||||
jcenter()
|
|
||||||
google()
|
google()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -21,7 +21,7 @@ object Versions {
|
|||||||
val kotlinSerializationPlugin = "1.5.10"
|
val kotlinSerializationPlugin = "1.5.10"
|
||||||
val atomicfu = "0.14.3-M2-2-SNAPSHOT" //NOTE: my linux arm32 and arm64 build
|
val atomicfu = "0.14.3-M2-2-SNAPSHOT" //NOTE: my linux arm32 and arm64 build
|
||||||
val nodePlugin = "1.3.0"
|
val nodePlugin = "1.3.0"
|
||||||
val dokkaPlugin = "1.4.0-rc"
|
val dokkaPlugin = "1.5.0"
|
||||||
val taskTreePlugin = "1.5"
|
val taskTreePlugin = "1.5"
|
||||||
val kotlinBigNumVersion = "0.2.8"
|
val kotlinBigNumVersion = "0.2.8"
|
||||||
val jna = "5.7.0"
|
val jna = "5.7.0"
|
||||||
@ -31,7 +31,7 @@ object Versions {
|
|||||||
val timber = "4.7.1"
|
val timber = "4.7.1"
|
||||||
val kodeinVersion = "7.1.0"
|
val kodeinVersion = "7.1.0"
|
||||||
|
|
||||||
val resourceLoader = "1.3.10"
|
val resourceLoader = "2.0.1"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -67,10 +67,10 @@ object Deps {
|
|||||||
object Js {
|
object Js {
|
||||||
|
|
||||||
object JsVersions {
|
object JsVersions {
|
||||||
val react = "16.13.1-pre.124-kotlin-1.4.10"
|
val react = "17.0.2-pre.218-kotlin-1.5.21"
|
||||||
val reactNpm = "16.13.1"
|
val reactNpm = "17.0.2"
|
||||||
val styled = "5.2.0-pre.124-kotlin-1.4.10"
|
val styled = "5.3.0-pre.218-kotlin-1.5.21"
|
||||||
val styledNpm = "1.0.0"
|
val styledNpm = "5.3.0"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -84,9 +84,9 @@ object Deps {
|
|||||||
val ktorClientWebSockets = "io.ktor:ktor-client-websockets-js:${Versions.ktor}"
|
val ktorClientWebSockets = "io.ktor:ktor-client-websockets-js:${Versions.ktor}"
|
||||||
|
|
||||||
object React {
|
object React {
|
||||||
val react = "org.jetbrains:kotlin-react:${JsVersions.react}"
|
val react = "org.jetbrains.kotlin-wrappers:kotlin-react:${JsVersions.react}"
|
||||||
val reactDom = "org.jetbrains:kotlin-react-dom:${JsVersions.react}"
|
val reactDom = "org.jetbrains.kotlin-wrappers:kotlin-react-dom:${JsVersions.react}"
|
||||||
val styled = "org.jetbrains:kotlin-styled:${JsVersions.styled}"
|
val styled = "org.jetbrains.kotlin-wrappers:kotlin-styled:${JsVersions.styled}"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -96,7 +96,7 @@ object Deps {
|
|||||||
val libsodiumWrappers = Pair("libsodium-wrappers-sumo", "0.7.8")
|
val libsodiumWrappers = Pair("libsodium-wrappers-sumo", "0.7.8")
|
||||||
val reactPair = Pair("react", JsVersions.reactNpm)
|
val reactPair = Pair("react", JsVersions.reactNpm)
|
||||||
val reactDomPair = Pair("react-dom", JsVersions.reactNpm)
|
val reactDomPair = Pair("react-dom", JsVersions.reactNpm)
|
||||||
val styledComponentsPair = Pair("styled-components", "5.2.0")
|
val styledComponentsPair = Pair("styled-components", JsVersions.styledNpm)
|
||||||
val inlineStylePrefixesPair = Pair("inline-style-prefixer", "6.0.0")
|
val inlineStylePrefixesPair = Pair("inline-style-prefixer", "6.0.0")
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -114,7 +114,7 @@ object Deps {
|
|||||||
|
|
||||||
val kotlinPoet = "com.squareup:kotlinpoet:${Versions.kotlinPoet}"
|
val kotlinPoet = "com.squareup:kotlinpoet:${Versions.kotlinPoet}"
|
||||||
|
|
||||||
val resourceLoader = "co.libly:resource-loader:${Versions.resourceLoader}"
|
val resourceLoader = "com.goterl:resource-loader:${Versions.resourceLoader}"
|
||||||
|
|
||||||
object Delegated {
|
object Delegated {
|
||||||
val jna = "net.java.dev.jna:jna:${Versions.jna}"
|
val jna = "net.java.dev.jna:jna:${Versions.jna}"
|
||||||
|
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@ -16,6 +16,6 @@
|
|||||||
|
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.0-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-bin.zip
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
|
@ -30,8 +30,6 @@ plugins {
|
|||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
jcenter()
|
|
||||||
|
|
||||||
}
|
}
|
||||||
group = ReleaseInfo.group
|
group = ReleaseInfo.group
|
||||||
version = ReleaseInfo.version
|
version = ReleaseInfo.version
|
||||||
|
@ -47,7 +47,6 @@ val sonatypeUsernameEnv: String? = System.getenv()["SONATYPE_USERNAME"]
|
|||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
jcenter()
|
|
||||||
maven {
|
maven {
|
||||||
url = uri("https://oss.sonatype.org/content/repositories/snapshots")
|
url = uri("https://oss.sonatype.org/content/repositories/snapshots")
|
||||||
}
|
}
|
||||||
@ -604,21 +603,19 @@ tasks {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
dokkaJavadoc {
|
|
||||||
|
create<Jar>("javadocJar") {
|
||||||
|
dependsOn(dokkaHtml)
|
||||||
|
archiveClassifier.set("javadoc")
|
||||||
|
from(dokkaHtml.get().outputDirectory)
|
||||||
|
}
|
||||||
|
|
||||||
|
dokkaHtml {
|
||||||
println("Dokka !")
|
println("Dokka !")
|
||||||
dokkaSourceSets {
|
dokkaSourceSets {
|
||||||
create("commonMain") {
|
|
||||||
displayName = "common"
|
|
||||||
platform = "common"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
create<Jar>("javadocJar") {
|
|
||||||
dependsOn(dokkaJavadoc)
|
|
||||||
archiveClassifier.set("javadoc")
|
|
||||||
from(dokkaJavadoc.get().outputDirectory)
|
|
||||||
}
|
|
||||||
if (getHostOsName() == "linux" && getHostArchitecture() == "x86-64") {
|
if (getHostOsName() == "linux" && getHostArchitecture() == "x86-64") {
|
||||||
val jvmTest by getting(Test::class) {
|
val jvmTest by getting(Test::class) {
|
||||||
testLogging {
|
testLogging {
|
||||||
@ -755,18 +752,5 @@ publishing {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//configurations.forEach {
|
|
||||||
//
|
|
||||||
// if (it.name == "linuxCompileKlibraries") {
|
|
||||||
// println("Configuration name: ${it.name}")
|
|
||||||
// it.attributes {
|
|
||||||
// this.keySet().forEach { key ->
|
|
||||||
// val attribute = getAttribute(key)
|
|
||||||
// println(" |-- Attribute $key ${attribute}")
|
|
||||||
// attribute(org.jetbrains.kotlin.gradle.plugin.ProjectLocalConfigurations.ATTRIBUTE, "publicZ")
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//}
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
package com.ionspin.kotlin.crypto
|
package com.ionspin.kotlin.crypto
|
||||||
|
|
||||||
import co.libly.resourceloader.FileLoader
|
import com.goterl.resourceloader.SharedLibraryLoader
|
||||||
import co.libly.resourceloader.SharedLibraryLoader
|
|
||||||
import com.sun.jna.Native
|
import com.sun.jna.Native
|
||||||
import com.sun.jna.Platform
|
import com.sun.jna.Platform
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
@ -32,7 +32,6 @@ plugins {
|
|||||||
kotlin(PluginsDeps.kotlinSerializationPlugin) version Versions.kotlinSerializationPlugin
|
kotlin(PluginsDeps.kotlinSerializationPlugin) version Versions.kotlinSerializationPlugin
|
||||||
|
|
||||||
}
|
}
|
||||||
org.jetbrains.kotlin.gradle.targets.js.npm.NpmResolverPlugin.apply(project)
|
|
||||||
|
|
||||||
val sonatypeStaging = "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
|
val sonatypeStaging = "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
|
||||||
val sonatypeSnapshots = "https://oss.sonatype.org/content/repositories/snapshots/"
|
val sonatypeSnapshots = "https://oss.sonatype.org/content/repositories/snapshots/"
|
||||||
@ -41,8 +40,6 @@ val sonatypeSnapshots = "https://oss.sonatype.org/content/repositories/snapshots
|
|||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
jcenter()
|
|
||||||
maven("https://dl.bintray.com/terl/lazysodium-maven")
|
|
||||||
maven("https://oss.sonatype.org/content/repositories/snapshots/")
|
maven("https://oss.sonatype.org/content/repositories/snapshots/")
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -63,28 +60,28 @@ kotlin {
|
|||||||
android()
|
android()
|
||||||
runningOnLinuxx86_64 {
|
runningOnLinuxx86_64 {
|
||||||
jvm()
|
jvm()
|
||||||
js(IR) {
|
// js(IR) {
|
||||||
browser {
|
// browser {
|
||||||
webpackTask {
|
// webpackTask {
|
||||||
|
//
|
||||||
}
|
// }
|
||||||
testTask {
|
// testTask {
|
||||||
useKarma {
|
// useKarma {
|
||||||
useChrome()
|
// useChrome()
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
nodejs {
|
// nodejs {
|
||||||
testTask {
|
// testTask {
|
||||||
useMocha() {
|
// useMocha() {
|
||||||
timeout = "10s"
|
// timeout = "10s"
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
// binaries.executable()
|
// binaries.executable()
|
||||||
|
|
||||||
}
|
// }
|
||||||
|
|
||||||
|
|
||||||
linuxX64("linux") {
|
linuxX64("linux") {
|
||||||
@ -205,11 +202,7 @@ kotlin {
|
|||||||
implementation("androidx.core:core-ktx:1.3.2")
|
implementation("androidx.core:core-ktx:1.3.2")
|
||||||
implementation("androidx.constraintlayout:constraintlayout:2.0.2")
|
implementation("androidx.constraintlayout:constraintlayout:2.0.2")
|
||||||
implementation("com.google.android.material:material:1.3.0-alpha03")
|
implementation("com.google.android.material:material:1.3.0-alpha03")
|
||||||
// implementation("androidx.ui:ui-tooling:$composeDevVersion")
|
|
||||||
// implementation("androidx.ui:ui-layout:$composeDevVersion")
|
|
||||||
// implementation("androidx.ui:ui-material:$composeDevVersion")
|
|
||||||
// implementation("androidx.ui:ui-foundation:$composeDevVersion")
|
|
||||||
// implementation("androidx.ui:ui-framework:$composeDevVersion")
|
|
||||||
implementation(Deps.Android.coroutines)
|
implementation(Deps.Android.coroutines)
|
||||||
implementation(Deps.Android.timber)
|
implementation(Deps.Android.timber)
|
||||||
// implementation("androidx.compose:compose-runtime:$composeDevVersion")
|
// implementation("androidx.compose:compose-runtime:$composeDevVersion")
|
||||||
@ -244,7 +237,7 @@ kotlin {
|
|||||||
val nativeMain by getting {
|
val nativeMain by getting {
|
||||||
dependsOn(commonMain)
|
dependsOn(commonMain)
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation(Deps.Desktop.libui)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
nativeMain
|
nativeMain
|
||||||
@ -252,7 +245,7 @@ kotlin {
|
|||||||
val nativeMain by creating {
|
val nativeMain by creating {
|
||||||
dependsOn(commonMain)
|
dependsOn(commonMain)
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation(Deps.Desktop.libui)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
nativeMain
|
nativeMain
|
||||||
@ -291,29 +284,30 @@ kotlin {
|
|||||||
implementation(kotlin(Deps.Jvm.reflection))
|
implementation(kotlin(Deps.Jvm.reflection))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
val jsMain by getting {
|
// val jsMain by getting {
|
||||||
dependencies {
|
// dependencies {
|
||||||
implementation(kotlin(Deps.Js.stdLib))
|
// implementation(kotlin(Deps.Js.stdLib))
|
||||||
implementation(Deps.Js.coroutines)
|
// implementation(Deps.Js.coroutines)
|
||||||
|
//
|
||||||
// React
|
//
|
||||||
implementation(Deps.Js.React.react)
|
// // React
|
||||||
implementation(Deps.Js.React.reactDom)
|
// implementation(Deps.Js.React.react)
|
||||||
implementation(npm(Deps.Js.Npm.reactPair.first, Deps.Js.Npm.reactPair.second))
|
// implementation(Deps.Js.React.reactDom)
|
||||||
implementation(npm(Deps.Js.Npm.reactDomPair.first, Deps.Js.Npm.reactDomPair.second))
|
//// implementation(npm(Deps.Js.Npm.reactPair.first, Deps.Js.Npm.reactPair.second))
|
||||||
|
//// implementation(npm(Deps.Js.Npm.reactDomPair.first, Deps.Js.Npm.reactDomPair.second))
|
||||||
// Styled
|
//
|
||||||
implementation(Deps.Js.React.styled)
|
// // Styled
|
||||||
implementation(npm(Deps.Js.Npm.styledComponentsPair.first, Deps.Js.Npm.styledComponentsPair.second))
|
// implementation(Deps.Js.React.styled)
|
||||||
implementation(npm(Deps.Js.Npm.inlineStylePrefixesPair.first, Deps.Js.Npm.inlineStylePrefixesPair.second))
|
//// implementation(npm(Deps.Js.Npm.styledComponentsPair.first, Deps.Js.Npm.styledComponentsPair.second))
|
||||||
|
//// implementation(npm(Deps.Js.Npm.inlineStylePrefixesPair.first, Deps.Js.Npm.inlineStylePrefixesPair.second))
|
||||||
}
|
//
|
||||||
}
|
// }
|
||||||
val jsTest by getting {
|
// }
|
||||||
dependencies {
|
// val jsTest by getting {
|
||||||
implementation(kotlin(Deps.Js.test))
|
// dependencies {
|
||||||
}
|
// implementation(kotlin(Deps.Js.test))
|
||||||
}
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
val linuxMain by getting {
|
val linuxMain by getting {
|
||||||
dependsOn(nativeMain)
|
dependsOn(nativeMain)
|
||||||
@ -481,12 +475,12 @@ tasks {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
val jsNodeTest by getting(KotlinJsTest::class) {
|
// val jsNodeTest by getting(KotlinJsTest::class) {
|
||||||
testLogging {
|
// testLogging {
|
||||||
events("PASSED", "FAILED", "SKIPPED")
|
// events("PASSED", "FAILED", "SKIPPED")
|
||||||
showStandardStreams = true
|
// showStandardStreams = true
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
import com.ionspin.kotlin.crypto.hash.Hash
|
import com.ionspin.kotlin.crypto.hash.Hash
|
||||||
import com.ionspin.kotlin.crypto.util.encodeToUByteArray
|
import com.ionspin.kotlin.crypto.util.encodeToUByteArray
|
||||||
import com.ionspin.kotlin.crypto.util.toHexString
|
import com.ionspin.kotlin.crypto.util.toHexString
|
||||||
import kotlinx.css.br
|
|
||||||
import react.RBuilder
|
import react.RBuilder
|
||||||
import react.RComponent
|
import react.RComponent
|
||||||
import react.RProps
|
import react.RProps
|
||||||
|
@ -2,5 +2,4 @@ import com.ionspin.kotlin.crypto.sample.Sample
|
|||||||
|
|
||||||
fun main() : Unit {
|
fun main() : Unit {
|
||||||
Sample.runSample()
|
Sample.runSample()
|
||||||
ui()
|
|
||||||
}
|
}
|
||||||
|
@ -1,30 +0,0 @@
|
|||||||
import com.ionspin.kotlin.crypto.hash.Hash
|
|
||||||
import com.ionspin.kotlin.crypto.util.encodeToUByteArray
|
|
||||||
import com.ionspin.kotlin.crypto.util.toHexString
|
|
||||||
import libui.ktx.TextArea
|
|
||||||
import libui.ktx.appWindow
|
|
||||||
import libui.ktx.button
|
|
||||||
import libui.ktx.textarea
|
|
||||||
import libui.ktx.vbox
|
|
||||||
|
|
||||||
fun ui() = appWindow(
|
|
||||||
title = "Hello",
|
|
||||||
width = 320,
|
|
||||||
height = 240
|
|
||||||
) {
|
|
||||||
val hash = Hash.sha512("123".encodeToUByteArray())
|
|
||||||
val text = "Hash (SHA512) of 123: ${hash.toHexString()}"
|
|
||||||
vbox {
|
|
||||||
lateinit var scroll: TextArea
|
|
||||||
|
|
||||||
button("Test") {
|
|
||||||
action {
|
|
||||||
scroll.append(text.trimMargin())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
scroll = textarea {
|
|
||||||
readonly = true
|
|
||||||
stretchy = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -17,11 +17,7 @@
|
|||||||
|
|
||||||
pluginManagement {
|
pluginManagement {
|
||||||
repositories {
|
repositories {
|
||||||
maven("https://dl.bintray.com/kotlin/kotlin-eap")
|
|
||||||
maven("https://dl.bintray.com/kotlin/kotlin-dev")
|
|
||||||
|
|
||||||
mavenCentral()
|
mavenCentral()
|
||||||
|
|
||||||
maven("https://plugins.gradle.org/m2/")
|
maven("https://plugins.gradle.org/m2/")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user