Jar does not contain plugin.yml

Discussion in 'Plugin Development' started by subplz, Nov 24, 2020.

Thread Status:
Not open for further replies.
  1. Offline

    subplz

    Hi,

    So this is my first time using Gradle and I get this error when I try and load my plugin I get this error:

    Code:
    org.bukkit.plugin.InvalidDescriptionException: Invalid plugin.yml
    
        at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPluginLoader.java:152) ~[server.jar:git-Bukkit-18fbb24]
        at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:133) [server.jar:git-Bukkit-18fbb24]
        at org.bukkit.craftbukkit.v1_8_R3.CraftServer.loadPlugins(CraftServer.java:289) [server.jar:git-Bukkit-18fbb24]
        at org.bukkit.craftbukkit.v1_8_R3.CraftServer.<init>(CraftServer.java:251) [server.jar:git-Bukkit-18fbb24]
        at net.minecraft.server.v1_8_R3.PlayerList.<init>(PlayerList.java:69) [server.jar:git-Bukkit-18fbb24]
        at net.minecraft.server.v1_8_R3.DedicatedPlayerList.<init>(SourceFile:14) [server.jar:git-Bukkit-18fbb24]
        at net.minecraft.server.v1_8_R3.DedicatedServer.init(DedicatedServer.java:179) [server.jar:git-Bukkit-18fbb24]
        at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:504) [server.jar:git-Bukkit-18fbb24]
        at java.base/java.lang.Thread.run(Thread.java:832) [?:?]
    Caused by: java.io.FileNotFoundException: Jar does not contain plugin.yml
        ... 9 more
    Here is my build.gradle:

    Code:
    processResources {
        from('src/main/resources') {
            include 'plugin.yml'
            expand(
                    name: project.parent.name,
                    version: project.parent.version
            )
        }
    }
    upload_2020-11-24_16-39-46.png

    What's wrong here?
     
  2. Online

    timtower Administrator Administrator Moderator

    @subplz Open up the jar with a zip program, where is the yml?
     
  3. Offline

    subplz

    As I said I am new to Gradle and I don't even know where the jar gets generated. I know the error because I use intellij's debugger
     
  4. Online

    timtower Administrator Administrator Moderator

    Impressive that you start a server with a debugger, have not seen that before.
    Do you know where the server is located? Or how it is started?
     
  5. Offline

    subplz

    It's a local server and it's started by JAR Application
     
  6. Online

    timtower Administrator Administrator Moderator

    Server has a location, location has a plugins directory.
     
  7. Offline

    subplz

    Wdym it's just in my desktop and the plugins folder is where it should always be
     
  8. Online

    timtower Administrator Administrator Moderator

    @subplz So why are you unable to find the jar for the generated plugin?
     
Thread Status:
Not open for further replies.

Share This Page