Skip to content

Crystalsage/martini

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Martini

Martini is a Rust based INI file parser. It was born during my recreational programming sessions.

About INI files

INI files are configuration files used for computer software configuration (typically Windows). Each file describes several named sections . These sections have key-value pairs inside of them.

The file format isn't too formally defined. There are some things that are standard and some things which vary. The goals section defines all specifications (to be) implemented in this project.

Goals

We'd like to achieve parsing for following features and properties. Some of these are implicitly guaranteed.

Basic features

  • Sections ([section])
  • Keys/Properties (key=value)
  • Case sensitivity
  • Comments (; is a comment)
  • Irrelevant ordering of sections

Varying features

  • Blank properties (There's no value. e.g. key=)
  • Global properties
  • Different delimiters for properties:
    • <space>
    • :
  • Hierarchy: Nesting the section
    • [section.subsection]
    • [.subsection] where nesting under section is inferred
  • Variants of comments:
    • #,
  • Duplicate properties with multiple parsing strategies:
    • Ignore: Ignore the latest conflicting duplicate.
    • Overwrite: Overwrite the original property with the new one.
    • Allow multiple: Allow multiple values to co-exist.

About

Rust based INI file parser.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages