Keeping comments in configs

Discussion in 'Plugin Development' started by Minnymin3, Jun 23, 2013.

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

    Minnymin3

    Is there any way to keep the comments (the lines that start with #) in configs when writing to the config via FileConfigurations? Its a pain how every time that the config is modified the comments are removed...
     
  2. Offline

    caseif

    It's a pain, but there isn't a way to fix it other than manually sorting through the lines and modifying them outside of the Bukkit API.
     
  3. Offline

    Minnymin3

    Aww... Was trying to avoid that... *le sigh*
     
  4. Offline

    Wingzzz

    Aren't you just supposed to ensure there is a space after # ? Try that, my plugin is currently having issues with maven, so I can't really check.
     
  5. Offline

    Minnymin3

    Wingzzz
    Il try it but I doubt that it'l work...

    IT WORKS OMG THANK YOU SO MUCH OMGOMG I LIKE COMMENTS CAN YOU TELL?
     
    Wingzzz likes this.
  6. Offline

    Wingzzz

    Hehe, yeah I love them too, and remember once seeing that's how Bukkit (or I guess SnakeYaml) handles the parsing.
     
Thread Status:
Not open for further replies.

Share This Page