Discord bot that provides fun image editing commands, such as image captioning. View the list of commands with /help
.
- In the IDEA main menu, select
Import Project
(orFile
→Open…
if you already have a project open). - Select the project's
build.gradle.kts
file to import the project. - Go to
File
→Project Structure
→Project Settings
→Project
and setSDK
to a Java 17 or higher SDK. - Optional, but recommended: By default, IntelliJ delegates to Gradle to build the project. This is unnecessary for this project and causes longer build times. To make it use the builtin compiler:
- Open the
Gradle Settings
dialog from the Gradle tab. - Change the
Build and run using
andRun tests using
fields toIntelliJ IDEA
. - Go to
File
→Project Structure
→Project
and setProject compiler output
to$PROJECT_DIR$/out
.
- Open the
- Run
io.github.shaksternano.borgar.core.Main#main
- It should fail to run the first time due to missing arguments such as the Discord bot token, so put those in the
Program arguments
field under theMain
run configuration →Edit Configurations...
.
- Run in a terminal from the same directory as the project directory
./gradlew build
on GNU/Linux and Mac, orgradlew build
on Windows. - Alternatively, in IntelliJ IDEA, open the Gradle tab on the right and execute
build
underTasks
→build
. After this is done once, thebuild
task should appear in the run configurations. - The JAR should appear in
${projectDir}/build/libs
, and should be calledborgar-VERSION.jar
. - To execute the jar, run the command
java -jar borgar-{VERSION}.jar DISCORD_BOT_TOKEN={TOKEN}
. For example,java -jar borgar-1.0.0.jar DISCORD_BOT_TOKEN=123456789