Home > Mobile >  Not sure what a .jar file (uploaded onto the plugins folder on minecraft server) should contain
Not sure what a .jar file (uploaded onto the plugins folder on minecraft server) should contain

Time:11-26

I am using eclipse (Maven) to create a Bukkit/Spigot plugin for Minecraft using the Java programming language.

I am using Shockbyte to host the server for the game (a paper server) and am uploading the '.jar' file into the 'plugins' folder of the server in order for it to record information from the game.

Do I only need to export the main.java file that contains the source code to a .jar file (screenshot 1)?

Or do I need to export the pom.xml and plugin.yml to .jar files too (also seen in screenshot 1)?

If no for the latter question, do I need to add the plugin.yml file directly into my plugins folder on the minecraft server (seen in screenshot 2)?

Would be so grateful for a helping hand!

Screenshot 1:

enter image description here

Screenshot 2:

enter image description here

CodePudding user response:

The plugin.yml file does need to be included in the JAR file. The pom.xml does not need to be (although it would not hurt anything if it were). If you are using Maven, running mvn clean package will create a JAR in the target folder within your project directory that will contain plugin.yml but not pom.xml.

  • Related