The ConfigParser module contains a parser for simple configuration files, similar to what's found in Microsoft's INI files.
You can also find a summary of the API for the ConfigParser module.
Here is an example configuration file for a program
You could create this programmatically:
- import mlib.configparser;
- void main()
- {
- auto parser = new ConfigParser();
- parser.addSection("general");
- parser.addOption("general", "directory", "$HOME/.local/share/medialist");
- parser.addOption("general", "verify_delete", "no");
- parser.addSection("cli");
- parser.addOption("cli", "verify_delete", "yes");
- }