update template

This commit is contained in:
InsanusMokrassar 2022-06-17 00:36:25 +06:00
parent 966cff5795
commit f42c8da1ca
6 changed files with 36 additions and 37 deletions

3
.gitignore vendored
View File

@ -11,3 +11,6 @@ out/
local.properties
secret.gradle
local.*
local.*/

View File

@ -1,43 +1,30 @@
buildscript {
repositories {
jcenter()
mavenCentral()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "org.jetbrains.kotlin:kotlin-serialization:$kotlin_version"
classpath libs.kotlin.gradle.plugin
classpath libs.kotlin.serialization.plugin
}
}
plugins {
id 'org.jetbrains.kotlin.jvm' version "$kotlin_version"
id "org.jetbrains.kotlin.plugin.serialization" version "$kotlin_version"
id "org.jetbrains.kotlin.kapt" version "$kotlin_version"
alias libs.plugins.kotlin.jvm
alias libs.plugins.kotlin.serialization
id 'application'
}
repositories {
jcenter()
mavenCentral()
mavenLocal()
maven { url 'https://jitpack.io' }
maven { url "https://dl.bintray.com/insanusmokrassar/PlaguBot/" }
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation "dev.inmo:plagubot.bot:$plagubot_version"
kapt "com.github.matfax.klassindex:processor:$klassindex_version"
implementation libs.kotlin
implementation libs.plagubot
}
application {
mainClassName = 'dev.inmo.plagubot.AppKt'
}
kapt {
arguments {
arg("com.github.matfax.klassindex.IndexSubclasses", "dev.inmo.plagubot.Plugin")
arg("com.github.matfax.klassindex.IndexAnnotated", "dev.inmo.sdi.SDIIncluded")
}
}

View File

@ -1,17 +1,12 @@
{
"botToken": "1234567890:ABCDEFGHIJKLMNOP_qrstuvwxyz12345678",
"plugins": [
{
"type": "Hello",
"parameter": "Example"
}
"dev.inmo.plagubot.HelloPlugin"
],
"params": {
"defaultDatabase": [
"dev.inmo.plagubot.config.DatabaseConfig",
{
"url": "jdbc:sqlite:file:test?mode=memory&cache=shared"
}
]
"helloPlugin": {
"print": "Hello World"
},
"database": {
"url": "jdbc:sqlite:file:local.db?mode=memory&cache=shared"
}
}

View File

@ -2,7 +2,3 @@ kotlin.code.style=official
org.gradle.parallel=true
kotlin.js.generate.externals=true
kotlin.incremental=true
kotlin_version=1.6.10
klassindex_version=4.1.0-rc.1
plagubot_version=0.5.0

18
gradle/libs.versions.toml Normal file
View File

@ -0,0 +1,18 @@
[versions]
kotlin = "1.6.21"
plagubot = "1.1.1"
[libraries]
kotlin = { module = "org.jetbrains.kotlin:kotlin-stdlib", version.ref = "kotlin" }
plagubot = { module = "dev.inmo:plagubot.bot", version.ref = "plagubot" }
# Libs for classpath
kotlin-gradle-plugin = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlin" }
kotlin-serialization-plugin = { module = "org.jetbrains.kotlin:kotlin-serialization", version.ref = "kotlin" }
[plugins]
kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }

View File

@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists