-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,130 @@ | ||
|
||
# Created by https://www.toptal.com/developers/gitignore/api/intellij+iml,gradle,kotlin | ||
# Edit at https://www.toptal.com/developers/gitignore?templates=intellij+iml,gradle,kotlin | ||
|
||
### Intellij+iml ### | ||
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider | ||
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 | ||
|
||
# User-specific stuff | ||
.idea/**/workspace.xml | ||
.idea/**/tasks.xml | ||
.idea/**/usage.statistics.xml | ||
.idea/**/dictionaries | ||
.idea/**/shelf | ||
|
||
# Generated files | ||
.idea/**/contentModel.xml | ||
|
||
# Sensitive or high-churn files | ||
.idea/**/dataSources/ | ||
.idea/**/dataSources.ids | ||
.idea/**/dataSources.local.xml | ||
.idea/**/sqlDataSources.xml | ||
.idea/**/dynamic.xml | ||
.idea/**/uiDesigner.xml | ||
.idea/**/dbnavigator.xml | ||
|
||
# Gradle | ||
.idea/**/gradle.xml | ||
.idea/**/libraries | ||
|
||
# Gradle and Maven with auto-import | ||
# When using Gradle or Maven with auto-import, you should exclude module files, | ||
# since they will be recreated, and may cause churn. Uncomment if using | ||
# auto-import. | ||
# .idea/artifacts | ||
# .idea/compiler.xml | ||
# .idea/jarRepositories.xml | ||
# .idea/modules.xml | ||
# .idea/*.iml | ||
# .idea/modules | ||
# *.iml | ||
# *.ipr | ||
|
||
# CMake | ||
cmake-build-*/ | ||
|
||
# Mongo Explorer plugin | ||
.idea/**/mongoSettings.xml | ||
|
||
# File-based project format | ||
*.iws | ||
|
||
# IntelliJ | ||
out/ | ||
|
||
# mpeltonen/sbt-idea plugin | ||
.idea_modules/ | ||
|
||
# JIRA plugin | ||
atlassian-ide-plugin.xml | ||
|
||
# Cursive Clojure plugin | ||
.idea/replstate.xml | ||
|
||
# Crashlytics plugin (for Android Studio and IntelliJ) | ||
com_crashlytics_export_strings.xml | ||
crashlytics.properties | ||
crashlytics-build.properties | ||
fabric.properties | ||
|
||
# Editor-based Rest Client | ||
.idea/httpRequests | ||
|
||
# Android studio 3.1+ serialized cache file | ||
.idea/caches/build_file_checksums.ser | ||
|
||
### Intellij+iml Patch ### | ||
# Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-249601023 | ||
|
||
*.iml | ||
modules.xml | ||
.idea/misc.xml | ||
*.ipr | ||
|
||
### Kotlin ### | ||
# Compiled class file | ||
*.class | ||
|
||
# Log file | ||
*.log | ||
|
||
# BlueJ files | ||
*.ctxt | ||
|
||
# Mobile Tools for Java (J2ME) | ||
.mtj.tmp/ | ||
|
||
# Package Files # | ||
*.jar | ||
*.war | ||
*.nar | ||
*.ear | ||
*.zip | ||
*.tar.gz | ||
*.rar | ||
|
||
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml | ||
hs_err_pid* | ||
|
||
### Gradle ### | ||
.gradle | ||
build/ | ||
|
||
# Ignore Gradle GUI config | ||
gradle-app.setting | ||
|
||
# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored) | ||
!gradle-wrapper.jar | ||
|
||
# Cache of project | ||
.gradletasknamecache | ||
|
||
# # Work around https://youtrack.jetbrains.com/issue/IDEA-116898 | ||
# gradle/wrapper/gradle-wrapper.properties | ||
|
||
### Gradle Patch ### | ||
**/build/ | ||
|
||
# End of https://www.toptal.com/developers/gitignore/api/intellij+iml,gradle,kotlin |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Lavakord | ||
Extension of the [official LavaLink-Client](https://github.com/FredBoat/Lavalink-Client) to work with [Kord](https://github.com/kordlib/kord) | ||
|
||
**Both Kord and Lavakord is still in an experimental stage, as such we can't guarantee API stability between releases. While we'd love for you to try out our library, we don't recommend you use this in production just yet.** | ||
|
||
Lavalink download: [https://github.com/Frederikam/Lavalink](https://github.com/Frederikam/Lavalink#server-configuration) | ||
|
||
# Download | ||
You can get Lavakord from here: [https://package-search.jetbrains.com/package?id=me.schlaubi%3Alavakord](https://package-search.jetbrains.com/package?id=me.schlaubi%3Alavakord) (You need `jcenter()` and jitpack though) | ||
|
||
# Usage | ||
You can create a `Lavalink` object like this | ||
```kotlin | ||
val lavalink = kord.lavalink() | ||
|
||
// or | ||
|
||
val lavalink = kord.lavalink { | ||
autoReconnect = false | ||
} | ||
``` | ||
|
||
You can obtain and use a `Link` like this | ||
```kotlin | ||
val link = guild.getLink(lavalink) | ||
|
||
link.connect(channel) | ||
|
||
// use lavalink stuff like player | ||
|
||
link.disconnect() | ||
``` | ||
|
||
# Documentation | ||
For more info please use the [example](https://github.com/DRSchlaubi/Lavakord/blob/master/example) or [Dokka docs](https://p.mik.wtf/lavakord/) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile | ||
import com.jfrog.bintray.gradle.BintrayExtension | ||
import java.net.URL | ||
|
||
plugins { | ||
kotlin("jvm") version "1.4.10" | ||
id("com.jfrog.bintray") version "1.8.5" | ||
id("org.jetbrains.dokka") version "1.4.0" | ||
`maven-publish` | ||
} | ||
|
||
group = "me.schlaubi" | ||
version = "0.1" | ||
|
||
repositories { | ||
mavenCentral() | ||
maven("https://jitpack.io") | ||
maven("https://dl.bintray.com/kordlib/Kord") | ||
jcenter() | ||
} | ||
|
||
dependencies { | ||
api("com.github.FredBoat", "Lavalink-Client", "4.0") | ||
api("com.gitlab.kordlib.kord", "kord-core", "0.6.3") | ||
testImplementation(kotlin("test-junit")) | ||
} | ||
|
||
val javaComponent: SoftwareComponent = components["java"] | ||
|
||
tasks { | ||
val sourcesJar = task<Jar>("sourcesJar") { | ||
dependsOn(classes) | ||
archiveClassifier.set("sources") | ||
from(sourceSets["main"].allSource) | ||
} | ||
|
||
|
||
val javadocJar = task<Jar>("javadocJar") { | ||
dependsOn(dokkaHtml) | ||
group = JavaBasePlugin.DOCUMENTATION_GROUP | ||
archiveClassifier.set("javadoc") | ||
from(dokkaHtml) | ||
} | ||
|
||
publishing { | ||
publications { | ||
create<MavenPublication>("mavenJava") { | ||
from(javaComponent) | ||
artifact(sourcesJar) | ||
artifact(javadocJar) | ||
} | ||
} | ||
} | ||
|
||
withType<KotlinCompile> { | ||
kotlinOptions.jvmTarget = "1.8" | ||
} | ||
|
||
dokkaHtml { | ||
outputDirectory.set(file("docs/")) | ||
|
||
dokkaSourceSets { | ||
configureEach { | ||
includeNonPublic.set(false) | ||
|
||
jdkVersion.set(8) | ||
} | ||
} | ||
} | ||
} | ||
|
||
bintray { | ||
user = System.getenv("BINTRAY_USER") | ||
key = System.getenv("BINTRAY_KEY") | ||
setPublications("mavenJava") | ||
pkg { | ||
repo = "maven" | ||
name = "lavakord" | ||
setLicenses("MIT") | ||
vcsUrl = "https://github.com/DRSchlaubi/lavakord.git" | ||
version { | ||
name = project.version as String | ||
gpg { | ||
sign = true | ||
passphrase = System.getenv("GPG_PASS") | ||
} | ||
} | ||
} | ||
} | ||
|
||
|
||
fun BintrayExtension.pkg(block: BintrayExtension.PackageConfig.() -> Unit) = pkg(delegateClosureOf(block)) | ||
fun BintrayExtension.PackageConfig.version(block: BintrayExtension.VersionConfig.() -> Unit) = version(delegateClosureOf(block)) | ||
fun BintrayExtension.VersionConfig.gpg(block: BintrayExtension.GpgConfig.() -> Unit) = gpg(delegateClosureOf(block)) |