config-value-getopt: Interface between config-value and System.GetOpt

[ configuration, library, mit ] [ Propose Tags ] [ Report a vulnerability ]

This package allows to set command line configuration options from a file using the config-value syntax.


[Skip to Readme]

Modules

[Index] [Quick Jump]

Downloads

Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.1.0.0, 0.1.1.0, 0.1.1.1
Change log CHANGELOG.md
Dependencies base (>=4.8 && <4.15), config-value (>=0.7 && <0.8), text (>=1.2.1.3 && <1.3) [details]
Tested with ghc ==7.10.3
License MIT
Copyright 2016 Galois, Inc.
Author Eric Mertens
Maintainer emertens@galois.com
Revised Revision 1 made by EricMertens at 2020-03-27T16:44:45Z
Category Configuration
Home page https://github.com/GaloisInc/config-value-getopt
Bug tracker https://github.com/GaloisInc/config-value-getopt/issues
Source repo head: git clone https://github.com/GaloisInc/config-value-getopt
Uploaded by EricMertens at 2019-10-18T21:14:32Z
Distributions
Reverse Dependencies 1 direct, 0 indirect [details]
Downloads 2320 total (8 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2019-10-18 [all 1 reports]

Readme for config-value-getopt-0.1.1.1

[back to package description]

config-value-getopt

The config-value-getopt package allows GetOpt[1] specified options to be loaded from a configuration file in the config-value[2] format.

  • config-value section names are matched against the "long" option names in GetOpt.
  • Argument values can be provided as strings or numbers
  • An option will be omitted if its value is set to no
  • An option's argument will be omitted if its value is set to yes

Example:

address:       "::"
port:          9000
no-access-log: yes
hostname:      no

translates to

--address="::" --port="9000" --no-access-log
  1. https://hackage.haskell.org/package/base-4.8.2.0/docs/System-Console-GetOpt.html
  2. https://hackage.haskell.org/package/config-value