Default config w/comments, yet new config appends too?

Discussion in 'Plugin Development' started by darkhelmet, Jan 19, 2013.

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

    darkhelmet

    I use a system currently that will always copy the coded defaults I have setup for a config, combine with the actual config, and then save the result. This allows me to save a new config when they use the plugin the first time, and to automatically update the config when we add new config options.

    However, I need to start using comments to explain something in the config that might not be obvious. However, the saveConfig() won't save any comments from what I've heard. So I went with saveDefaultConfig(), which copies a commented-config file from the plugin source.

    However, when using saveDefaultConfig I can't add new options without messing up their config, and with saveConfig I can't use comments.

    Suggestions?
     
Thread Status:
Not open for further replies.

Share This Page