Inactive [ADMN] PermissionsHelper v1.0.3 - Generate a pastable permissions node list every reload [1185]

Discussion in 'Inactive/Unsupported Plugins' started by coolblinger, Aug 8, 2011.

  1. PermissionsHelper - Generate a pastable permissions node list every reload
    Version 1.0.3 | Download | GitHub
    Requested by @undeadmach1ne (original thread)

    PermissionsHelper generates a pastable list of permissions nodes, to make up for the lack of '*' permissions. This will only work if the plugins support SuperPerms, because it will pull the nodes from the plugin.yml files.

    Features:
    • Automatically generate and update a list of permissions nodes.
    Usage:
    The plugin will create the list automatically every reload, approximately thirty seconds after the plugin loads to prevent delaying other plugins.

    Tutorial video by @JoelDaMole789


    Changelog:
    Version 1.0.3
    • Made it compatible with the latest CraftBukkit build.
    Version 1.0.2
    • Added a list of plugins that did not have permissions nodes included
    Full changelog (open)
    Version 1.0.3
    • Made it compatible with the latest CraftBukkit build.
    Version 1.0.2
    • Added a list of plugins that did not have permissions nodes included
    Version 1.0.1
    • Added a dash in front of each permissions node
    Version 1.0
    • Initial release
    Got a feature requests or found bugs? Please post them to GitHub.
     
    DirkHBo, flames, Gonera and 3 others like this.
  2. Offline

    Sh00ck

    Nice Idea :)
     
  3. Offline

    Mr.Crude

    Maybe this will help me find those nasty permission nodes...:)
     
  4. Keep in mind that this only works of the plugins use SuperPerms, and thus have the nodes listed in their plugin.yml files.
     
  5. Offline

    undeadmach1ne

    its beautiful, thanks :)
     
  6. No problems. :)
     
  7. Offline

    EdTheLoon

    Does this plugin list the plugins that don't support SuperPerms and as a result couldn't fetch the nodes for?

    Edit: Just looked at your source and that answered my question. Will you be adding such a feature? It would make it a lot easier to know which plugins we would have to manually add nodes for
     
  8. Great idea, I'll add it in a second.

    I've uploaded version 1.0.2, which adds a list of plugins that did not have permissions nodes included at the end.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 18, 2016
  9. Offline

    Ruprect

  10. Offline

    EdTheLoon

    I was going to fork and send a pull request myself but you've beat me to it :p Still, I'm interested to see how you did it to see if you had the same idea about how to implement it -looks at source- :D
     
  11. Offline

    Dark_Balor

    Instead of doing after 30 sec, why don't you use the PluginListener, when a plugin is enabled, you read its permission and append it to your file ?
    And of course keep a list with all already generated plugin.

    Last thing, it don't works with every SuperPerm plugins ^^
    Example (mine) : AdminCmd. Because I didn't add any node in the plugin.yml (too boring to do for every command ) I use the Bukkit API to register it directly when I register my plugin commands ^^
     
  12. I thought most plugin devs that use SuperPerms did that. :)
    And I'm doing it this way to lessen server load. (altough it would probably not make much of a difference)
     
  13. Offline

    Dark_Balor

    I had more or less 30 commands when they add SuperPerm ^^' Imagine that each command have it's own node ... Adding to the plugin.yml ? I'm not crazy xD

    I just made a system to register it for me ^^

    (no difference at all, in all the case it will be only at launch, or when a plugin reload.)
     
  14. Offline

    mrvertigo27

    be ready for more support i messaged (almost all) Devs of the plugins that I use to include support for this plugin with the following message "please list your permissions node in your plugin.yml so we may extract them regularly and stay updated using permissionshelper" I realize its borderline spam however I'm not willing to write a personal message to 50+ devs :p
     
  15. Lol, thank you. :D
     
  16. Offline

    DrBreadgun

    TIS WAS THE BEST DISCOVERY EVER SINCE......AIR :D
     
  17. I hope people will start putting their permissions nodes in their plugin.yml files, because more then half of the plugins I use do not.
     
  18. Offline

    undeadmach1ne

    yeah that would be nice. quite a few of mine dont either. i just thought they were not up to date with superperms support yet. its good to see other people enjoying this idea. when i posted it in req it just fell off with no replies and no views so i thought it was a stupid idea. thanks again for making it man :) even if it only shows half my plugins thats still saving me a ton of time...and like you said, hopefully devs will start to include the nodes in plugin.yml now that this tool is out (and thus, support a fellow dev and his kickass plugin as well).
     
  19. Offline

    EdTheLoon

    In my opinion not putting your permissions in the plugin.yml is not user friendly and plugin friendly. More knowledged users could use the plugin.yml in your jar file to add permission nodes to their permissions configuration rather than reading it off of your plugin thread. And in the case of this mod, making it harder to obtain all the permission nodes required...so next time I write a SuperPerms supporting mod...I'll definitely be making sure it's done the right way by putting in the nodes in plugin.yml. Surely if you're going to list all your nodes for your plugins on your plugin release thread you can manage to (pretty much) copy and paste them into plugin.yml?
     
  20. Offline

    undeadmach1ne

    yeah i have to admit i didnt know that they were stored in there like that. if i did i likely wouldnt have requested a plugin like this lol...

    noob :rolleyes: (hahaw)
     
  21. Offline

    EdTheLoon

    Even if you did know this plugin is a great help because it does it for all of us lazy server admins :)
     
  22. Offline

    undeadmach1ne

  23. Offline

    EdTheLoon

    Only 2 of the plugins I run on my server have the permissions listed...my plugin (just updated to support SuperPerms) and another plugin I'm helping to develop. All the other plugins listed as not having any though :)
     
  24. Offline

    sheriff3

    thx i love you
     
  25. Offline

    RchGrav

    I'm sorry if this question is a bit derpy... but why is adding the dash in from of each permission significant? Does it negate the permission like in the old system, so these actually get removed to enable the permissions?

    Pasting the list adds the nodes and then you remove the dash to enable each one? If this is the case what is the purpose of the true/false setting in relation to the dash.

    I guess this is the source of my confusion in the way this plugin generated the list.

    Sorry if this is answered elsewhere.. I did a semi-diligent search to try to figure it out before asking.

    Thanks!

    Rich
     
  26. You need a dash in order to paste them into the .yml files. (correct me if I'm wrong)
     
  27. Offline

    RchGrav

    Well.. here what I since found out.. SuperPerms has what seems to be a number of in game commands which will add items to these config files and at the very least I should be able to follow the YAML formatting inside of the file as an example. I'm still wrapping my head around all of this... I'm still using 2.x legacy permissions and never jumped onto the 3.x or groupmanager bandwagon.. because everything worked. Now that I did a test run of the new permissions system I found a number of my plugins that don't have proper permissions to be used, even though I disabled the new system until I understand what is going on a little better.

    I'm redoing a "test server" for getting this working properly.. My server has been up and stable so long, I don't even have a parallel install to test new configurations on any more. That'll teach me.

    Rich
     
  28. Offline

    Celtic Minstrel

    Whereas I just went and added my 30 commands to the plugin.yml. :p (Well, it was more like 10 or 15, but the number of permissions for them certainly exceeded 30.) That said, I don't have all the permissions in the plugin.yml, because some are systematic based on various enums, or based on the loaded worlds, so I create those at load time through the API.

    You're not right. PermissionsEx needs the hyphen, yes, but PermissionsBukkit instead needs the suffix": true", and I would guess that bPermissions needs neither.

    You should probably not read from the plugin.yml for the permissions, as some plugins have so many permissions that it's not practical to do so; instead, you should fetch them through the Bukkit API (not entirely sure how to do this, but I'm fairly sure it's possible).

    Also, this is not as useful as it could be when a plugin provides a permissions node that covers all the permissions it provides, or when a plugin provides permissions that you would've want admins to have. As such, calling the list "pastable" is a bit of a stretch.

    I think you should be able to force your plugin to load (almost) last of all by adding this to your plugin.yml:
    Code:
    softdepend: [ZZZ]
    I say almost because it may not work if multiple plugins try to use the same trick. However, you can catch plugins that load after you by listening for the PLUGIN_LOAD event.
     
  29. Offline

    Discover

    Thank you SO much! This will finally help me switch to SuperPerms. :D Sucks that Permissions isn't supported. :(
     
  30. Offline

    Tauryuu

    Another amazing plugin by @coolblinger!
     

Share This Page