Version Number

Discussion in 'Spigot Plugin Development' started by TimLampen, May 15, 2015.

  1. Hey,
    I was wondering if anyone knew how to make it so that the version number of a plugin increments every time it is built in eclipse.

    This is cuz I am kinda lazy and forget sometimes

    Thanks,
    Tim
     
  2. version of the plugin?
    if so in what plugin.yml modified:

    name: {plugin name}
    version: 1.0 <============
    author: RuloGamer
    main: {main}
     
  3. What he is saying is everytime he updates the plugin he doesnt want to update the plugin.yml
     
  4. That is not possible sorry.
     
  5.  
  6. That's not possible with an ide, you could look into maven/gradle there COULD be a plugin for maven/gradle with that feature. Otherwise its working with {env.BUILD_NUMBER} in jenkins ci
     
    • Like Like x 1
  7. Whenever I make updates, I just copy and paste the project. That way, I have older versions as well.
     
    • Like Like x 1
  8. For version history I always suggest using git or any other scm tool
     
    • Agree Agree x 1
  9. I'm not sure if this is what you're looking for. It's not by any means automated versioning, but it's at least reduced. If you use Maven, you can use the following in your plugin.yml and Maven will auto-replace it with what is in the pom.xml when it builds:

    Code (YAML):
    name: ${project.name}
    version
    : ${project.version}

    This way, when you are updating your plugin, you just change the 'version' field in Maven, and it'll carry over in the plugin.yml file.