oleskiewicz / kv Goto Github PK
View Code? Open in Web Editor NEWkey-value config reader for C
License: GNU General Public License v3.0
key-value config reader for C
License: GNU General Public License v3.0
kv == kv is a simple, header-only key-value config reader for C. It is implemented using X Macros. The advantage of this approach is that it generates code for parsing, printing, and serialising the configuration files all at once. format ------ Configuration file is read from standard input, one line per field of the key-value struct. Each line is expected to follow `%s = %s\n` format. Conversions are provided for integers, double precision floats, booleans (formatted as: `T`, `True` or `true`), characters and strings. Empty keys and lines are silently discarded. Maximum length of keys and values is BUFSIZ. # comments can be removed with sed key1 = 1 # int key2 = 1.0 # double key3 = T # bool key4 = O # char key5 = / # char * key6 = 1,2,3 # int * usage ----- See included `example.c` and `example.conf` files, with Planck+15 cosmology data. make < example.conf sed 's/#.*//' | ./example Notice that `kv.h` header file must be included **after** defining a `KV` macro.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.