Add auto publish feature

This commit is contained in:
Wieland Schöbl
2020-08-14 22:43:53 +02:00
parent d15fb92acf
commit 7bf483ab32
15 changed files with 274 additions and 130 deletions

View File

@@ -7,15 +7,14 @@ import de.wulkanat.web.SiteWatcher
import kotlin.concurrent.timer
fun main() {
// TODO: move toke into file
val builder = JDABuilder.createLight(
Admin.token,
GatewayIntent.GUILD_MESSAGES, GatewayIntent.DIRECT_MESSAGES)
.addEventListeners(Bot())
.setActivity(Activity.watching("for new Blogposts"))
.build()
builder.addEventListener(Cli())
builder.addEventListener(ErrorHandler())
builder.awaitReady()
Channels.jda = builder