Closed f0o closed 3 years ago
After switching from Master to the 2.0
tag it does produce a jar but upon execution it errors with:
Error: Main method not found in class com.shimmermare.inviteroles.InviteRoles, please define the main method as:
public static void main(String[] args)
or a JavaFX application class must extend javafx.application.Application
The only tag that does yield a valid .jar is v1.0.1
You simply need to pass the environment variable "discord.token" as the exception tells you, then it works.
E.g
./mvnw package -Ddiscord.token=HERECOMESTHEBOTTOKEN
[INFO] --- spring-boot-maven-plugin:2.3.0.RELEASE:repackage (repackage) @ InviteRoles ---
[INFO] Replacing main artifact with repackaged archive
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 17.408 s
[INFO] Finished at: 2020-12-02T22:29:40+01:00
[INFO] ------------------------------------------------------------------------
@WtfJoke is right, you need to pass your Discord bot token.
Running on Maven 3.6.3 and OpenJDK 11