An open API service indexing awesome lists of open source software.

https://github.com/dbackowski/yaml_config_parser

YAML config parser.
https://github.com/dbackowski/yaml_config_parser

Last synced: 7 months ago
JSON representation

YAML config parser.

Awesome Lists containing this project

README

          

Usage: yaml_config_parser.rb [options]

-c, --config FILE YAML config file
-f, --file FILE File to parse
-h, --help Display this screen

Example:
data.yml source:

global:
host: 127.0.0.1
port: 8080

mail:
smtp: bar.com
from: foo@bar.com

config.txt source:

Host: #{global:host}
Port: #{global:port}

SMTP server: #{mail:smtp}
Mail from: #{mail:from}

After: ./yaml_config_parser.rb -c data.yml -f config.txt

config.txt source:

Host: 127.0.0.1
Port: 8080

SMTP server: bar.com
Mail from: foo@bar.com