Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/andimiller/recline
an opinionated derivation framework for decline
https://github.com/andimiller/recline
cats cats-effect command-line-parsing configuration scala
Last synced: 19 days ago
JSON representation
an opinionated derivation framework for decline
- Host: GitHub
- URL: https://github.com/andimiller/recline
- Owner: andimiller
- License: mit
- Created: 2019-06-18T20:05:05.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-12-02T16:32:26.000Z (about 5 years ago)
- Last Synced: 2024-11-18T00:11:57.694Z (3 months ago)
- Topics: cats, cats-effect, command-line-parsing, configuration, scala
- Language: Scala
- Homepage: https://recline.andimiller.net/
- Size: 708 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# recline
recline is an opinionated derivation framework for the excellent [decline](https://github.com/bkirwi/decline) command line parser.
## Motivation
This library is designed to be used with microservices where you'd like to configure them mostly through a configuration file, environment variables, or command line flags.
It assumes that command line flags should override environment variables, and they should both override the configuration file.
## Modes
It includes two modes, one which will derive an `Opt[T]` where `T` is your configuration case class, this will require most options to be passed in on the command line or via environment variables.
The second mode allows you to derive an `Opt[T => T]` which is intended to be layered on top of a configuration file, or a set of defaults.