Skip to content
parse simple KEY=VALUE config files
Common Lisp
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
t
README.md
package.lisp
simple-config-test.asd
simple-config.asd
simple-config.lisp

README.md

simple-config

ava fox

a library to load and parse simple config files of the format KEY = VALUE

attempts to parse each value into its proper lisp data type.

config example:

env = development
program-version=2
aws_bucket = config-bucket

Install

(ql:quickload :simple-config)

API

load-config - file-path &key parse-lists list-separator

Loads a config file from FILE-PATH

if PARSE-LISTS is non-nil VALUES are checked for LIST-SEPARATOR and split by it.

PARSE-LISTS defaults to t

LIST-SEPARATOR defaults to #\,

Returns t if successfully loaded, otherwise nil


config - key &optional default

Checks loaded config for KEY, returning nil if not found

If DEFAULT is given, returns it instead of nil if KEY isn't found


License

BSD 3-Clause

You can’t perform that action at this time.