How to configure permissions with YML file?

Discussion in 'Bukkit Help' started by Jaker232, May 24, 2011.

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

    Jaker232

    Hello there, it's me, Jaker232 again, with another issue. (This is new to me, so.)

    How do I configure plugins, but a YML is in the way (It's called "File" on my computer) and I was wondering why it is there. Can someone tell me how to get past it, so I can configure it's plugin?
     
  2. Offline

    GossamerSolid

    YML can be opened with any text editor (I suggest NotePad++ so you can get syntax highlighting)
     
  3. Offline

    Jaker232

    Okay, thanks!
     
  4. First I have to say that the response to your question is a respons made based on what I think you are asking since it's hard to read your english. (What language are you're main btw?).

    This is in no way any complain aimed at you, just an explanation if my answer happen to be about something you didn't mean. :)

    Ok, here goes:
    In your plugin-directory you have a .jar-file named permissions and if you have run the server once, you should hava a directory named "permissions" top, right?
    In the permissions directory there lies a .yml-file that when opened looks something like this:
    Code:
    ---
    plugin:
      permissions:
        system: 'default'
        copies: ''
    groups:
      Admins:
        default: false
        info:
          prefix: '&normal'
          suffix: '§multiplay'
          build: true
        inheritance: ''
        permissions:
          - '*'
      Default:
        default: true
        info:
          prefix: ''
          suffix: ''
          build: true
        inheritance: ''
        permissions:
          - 'essentials.help'
          - 'essentials.home'
          - 'essentials.motd'
          - 'essentials.rules'
          - 'essentials.sethome'
      Moderator:
        default: false
        info:
          prefix: ''
          suffix: ''
          build: true
        inheritance:
          - 'Default'
        permissions:
          - 'essentials.tp'
          - 'essentials.tphere'
    users:
      MPUKWebmaster:
        group: 'Admins'
        permissions: ''
      Meno:
        group: 'Admins'
        permissions: ''
      jamesrwpowell:
        group: 'Admins'
        permissions: ''
      marksteele:
        group: 'Admins'
        permissions: ''
      rdf:
        group: 'Moderator'
        permissions: ''
      sebastiannkl:
        group: 'Admins'
        permissions: ''
      zipperi:
        group: 'Moderator'
        permissions: ''
    
    Observe that I said "something like..." so it doesn't look exactly like this, I know.

    The first thing you should do is rename (if you haven't done so already) the .yml-file so that it has the same name as the world on your server. The name of the world is the name that the directoy that contains your world is named as. (The worlds directory lies at the same place as the server".
    If your server is named world (which is the defaultname) you should then rename the .yml-file to world.yml.

    When all this is done you are free to add any commands/rights that you want your different users to be able to use.

    This part:
    Code:
    groups:
       Admins:
         default: false
         info:
           prefix: '&normal'
           suffix: '§multiplay'
           build: true
         inheritance: ''
         permissions:
           - '*'
       Default:
         default: true
         info:
           prefix: ''
           suffix: ''
    is the part that contains the different groups the users on your server can be members in.
    The group default is the group that everyone that login becomes members in at first login. You can see this because it says "default: true" beneath it and every other group says "default: false". Should you change it to false and change the admins group to "default: true" than everyone that logs in will be admin.

    At the bottom of the Admins group you see that it says "Permissions:" and beneath it there is only "- '*'.
    That's because the admins should have all rights on the server and a '*' means everything.

    To add more things to the default group you need to check every plugin to see what different permissions they need.
    For the essentials plugin there is alot of different things you can give your members right to. For exampel the "Help" command. To give your users the right to type /help and get the help-menu you need to add - 'essentials.help' to the "default" permissions.

    If you add - 'essentials.help' to the default group, it should look like this:
    Code:
      Default:
        default: true
        info:
          prefix: ''
          suffix: ''
          build: true
        inheritance: ''
        permissions:
          - 'essentials.help'
    
    Remember that when you type in a permission you need to use 4 spaces before the -''. Do not use TAB or any other number of spaces since this would break the config.

    Or even easier, use the online permissions editor at: http://www.wi-alliance.com/yamlhelper/

    I guess this was a little more than you perhaps asked for, but I had so much time over... :p
     
    Jinnai likes this.
  5. Offline

    Jaker232

    I don't have a .yml file in there.

    It's empty.
     
  6. Offline

    jtlcr777

    The yml file should come with Permissions. If you just downloaded the jar by itself you need to start the server to trigger it to generate one for you.
     
  7. Offline

    Jaker232

    JTLCR, I always run the server so it generates the file. However, my permission doesn't say that.
     
  8. Then make a directory in your plugins folder and name the directory permissions.
    Then go to http://www.wi-alliance.com/yamlhelper/ and copy the text there (either copy it as it is to just get a function text, or set it up to your liking first). Create a text document inyour newly created permissions directory and rename the textfile to yourworld.yml (where yourworld is the name of your world :p).
    Past the text into that file and save.

    Now you have a .yml-file wich you can make all the changes in that you like.

    Also chech in the plugin directory that you don't have a .yml-file lying there. First time I installed permissions I didnt get any directory created either but a yml-file was in the plugins folder. Just remove it. :)
     
Thread Status:
Not open for further replies.

Share This Page