The Ini package provides support for parsing INI file formatted text.
// Parses the file 'example.ini' in the current working directory // Output all the content use "ini" use "files" actor Main new create(env:Env) => try let ini_file = File(FilePath(env.root as AmbientAuth, "example.ini")?) let sections = IniParse(ini_file.lines())? for section in sections.keys() do env.out.print("Section name is: " + section) for key in sections(section)?.keys() do env.out.print(key + " = " + sections(section)?(key)?) end end end
© 2016-2018, The Pony Developers
© 2014-2015, Causality Ltd.
Licensed under the BSD 2-Clause License.
https://stdlib.ponylang.io/ini--index