Generate Go structs from XML documents to simplify reading XML data in Go programs.
Zek is a command-line tool that generates Go struct definitions from XML documents. It solves the problem of manually writing Go structs to unmarshal XML data, saving developers time when integrating XML sources into Go applications. The tool outputs structs with appropriate XML tags that work with Go's standard `encoding/xml` package.
Go developers who need to read and process XML data in their applications, particularly those working with data integration, APIs, or legacy systems that use XML formats.
Zek offers a fast, schema-free way to generate Go structs from XML, reducing manual effort and potential errors. Unlike alternatives, it focuses on simplicity and practical use cases for reading XML, with features like example annotations and multi-file inference.
Generate a Go struct from XML.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Works directly on XML documents without needing XSD or DTD files, simplifying the setup process as highlighted in the Key Features.
Adds comments with example values from the XML using the -e flag, making field purposes clearer for developers, as shown in the annotated output examples.
Can infer a unified struct by analyzing multiple XML files together, useful for datasets with variations, demonstrated with archives and zip file processing.
Generates a single, concise struct definition, keeping the code readable and manageable, which is a stated priority in the philosophy.
All XML elements are mapped to string types without inference for other data types, requiring manual adjustments for numerical or boolean fields, as admitted in the downsides.
Cannot handle XML with recursive elements, limiting its use for complex schemas like Russian Doll strategies, which is explicitly listed as a downside.
Described as a buggy and unstable prototype in the README, making it risky for production use where reliability is essential.