Closed lucab closed 2 years ago
longer term I think we're going to need this parser to gracefully handle unknown features
I think you raised a fair point. Let's rework the parser here to log a warning and proceed on unrecognized line types.
Added one commit to detect&recover on unknown entry types, let me know if that meets your expectations now.
@cgwalters unless further comments, I'm going ahead and merging this.
This adds support for parsing entries from sysusers.d lines. Overall logic is organized around the 'nom' parser-combinator framework. It is now possible to roundtrip configuration entries, loading content from files as well as writing back data.