https://github.com/stackbuilders/keyword-args
Parses a configuration file containing keywords and arguments separated by spaces
https://github.com/stackbuilders/keyword-args
Last synced: 10 months ago
JSON representation
Parses a configuration file containing keywords and arguments separated by spaces
- Host: GitHub
- URL: https://github.com/stackbuilders/keyword-args
- Owner: stackbuilders
- License: mit
- Created: 2015-01-26T20:15:14.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2015-04-23T18:55:40.000Z (almost 11 years ago)
- Last Synced: 2025-02-25T05:34:54.176Z (11 months ago)
- Language: Haskell
- Homepage: https://hackage.haskell.org/package/keyword-args
- Size: 355 KB
- Stars: 1
- Watchers: 9
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://travis-ci.org/stackbuilders/keyword-args) [](http://hackage.haskell.org/package/keyword-args)
# Keyword Args
Parses a configuration file with keywords followed by arguments,
separated by a space. An example of a file in this format is the
`sshd_config` file.
The parser in this library strips out comments, and normalizes
whitespace. It includes a binary, `keyword-args`, which reads from
STDIN and emits a CSV file with two columns, containing the keyword
followed by the values.
## Executable Usage
Send input to STDIN, and the output will be a CSV with comments
stripped and with unnecessary whitespace removed.
```bash
$ printf "#Testing\nkeyword a bunch of values #comment" | keyword-args
keyword,"a bunch of values"
```
## Library Usage
This project exposes a library that is usable from Haskell programs
for extracting data from input in Keyword-Argument format.
## Author
Justin Leitgeb
## License
MIT
## Copyright
(C) 2015 Stack Builders Inc.