ycleptic 2.2.0__tar.gz → 2.2.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (68) hide show
  1. {ycleptic-2.2.0 → ycleptic-2.2.2}/CHANGELOG.md +17 -0
  2. ycleptic-2.2.2/PKG-INFO +167 -0
  3. ycleptic-2.2.2/README.md +120 -0
  4. ycleptic-2.2.2/docs/source/index.rst +46 -0
  5. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/usage/class.rst +2 -1
  6. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/usage/interactive_help.rst +5 -4
  7. ycleptic-2.2.2/docs/source/usage/quickstart.rst +72 -0
  8. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/usage/resource_file.rst +4 -4
  9. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/usage/the_base_config.rst +40 -8
  10. ycleptic-2.2.2/docs/source/usage/yclept_config-help.rst +41 -0
  11. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/usage/yclept_makedoc.rst +1 -1
  12. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/usage.rst +2 -1
  13. {ycleptic-2.2.0 → ycleptic-2.2.2}/pyproject.toml +1 -1
  14. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set.py +45 -0
  15. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/resources/example_base.yaml +2 -2
  16. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/yclept.py +15 -6
  17. ycleptic-2.2.0/PKG-INFO +0 -88
  18. ycleptic-2.2.0/README.md +0 -41
  19. ycleptic-2.2.0/docs/source/changelog.md +0 -5
  20. ycleptic-2.2.0/docs/source/index.rst +0 -26
  21. ycleptic-2.2.0/docs/source/usage/yclept_config-help.rst +0 -10
  22. {ycleptic-2.2.0 → ycleptic-2.2.2}/.envrc +0 -0
  23. {ycleptic-2.2.0 → ycleptic-2.2.2}/.github/workflows/ci.yaml +0 -0
  24. {ycleptic-2.2.0 → ycleptic-2.2.2}/.github/workflows/release.yaml +0 -0
  25. {ycleptic-2.2.0 → ycleptic-2.2.2}/.gitignore +0 -0
  26. {ycleptic-2.2.0 → ycleptic-2.2.2}/.readthedocs.yaml +0 -0
  27. {ycleptic-2.2.0 → ycleptic-2.2.2}/LICENSE +0 -0
  28. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/Makefile +0 -0
  29. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/make.bat +0 -0
  30. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/requirements.txt +0 -0
  31. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/_static/css/custom.css +0 -0
  32. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/about.rst +0 -0
  33. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/API.rst +0 -0
  34. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.cli.rst +0 -0
  35. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.dictthings.rst +0 -0
  36. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.errors.rst +0 -0
  37. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.makedoc.rst +0 -0
  38. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.resources.rst +0 -0
  39. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.rst +0 -0
  40. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.stringthings.rst +0 -0
  41. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.walkers.rst +0 -0
  42. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/api/ycleptic.yclept.rst +0 -0
  43. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/changelog.rst +0 -0
  44. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/conf.py +0 -0
  45. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/installation.rst +0 -0
  46. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/roadmap.md +0 -0
  47. {ycleptic-2.2.0 → ycleptic-2.2.2}/docs/source/usage/the_user_config.rst +0 -0
  48. {ycleptic-2.2.0 → ycleptic-2.2.2}/pytest.ini +0 -0
  49. {ycleptic-2.2.0 → ycleptic-2.2.2}/scripts/release.sh +0 -0
  50. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/__init__.py +0 -0
  51. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/conftest.py +0 -0
  52. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/README.md +0 -0
  53. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/mypackage/__init__.py +0 -0
  54. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/mypackage/config.py +0 -0
  55. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/mypackage/data/__init__.py +0 -0
  56. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/mypackage/data/base.yaml +0 -0
  57. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/mypackage/docs/source/intro.rst +0 -0
  58. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/mypackage/otherstuff/stuff.py +0 -0
  59. {ycleptic-2.2.0 → ycleptic-2.2.2}/tests/test_set/test_package/rootdir/setup.py +0 -0
  60. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/__init__.py +0 -0
  61. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/cli.py +0 -0
  62. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/dictthings.py +0 -0
  63. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/errors.py +0 -0
  64. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/makedoc.py +0 -0
  65. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/resources/__init__.py +0 -0
  66. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/src/__init__.py +0 -0
  67. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/stringthings.py +0 -0
  68. {ycleptic-2.2.0 → ycleptic-2.2.2}/ycleptic/walkers.py +0 -0
@@ -5,6 +5,23 @@ The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
+ ## [2.2.2] - 2026-08-13
9
+
10
+ ### Added
11
+ - Status badges (PyPI version, supported Python versions, CI, documentation, license) on the README and the documentation landing page
12
+
13
+ ### Fixed
14
+ - Interactive `config-help` no longer ends with an uncaught traceback when stdin reaches EOF (piped or redirected input) or when the user presses Ctrl-C; either case now quits the session cleanly, exactly as if the user had typed `!`
15
+
16
+ ## [2.2.1] - 2026-07-21
17
+
18
+ ### Changed
19
+ - Repositioned the README and documentation landing page to lead with Ycleptic's distinctive workflow — one YAML schema as a single source of truth for validation, generated documentation, and interactive help — with an honest "when to use it" comparison to pydantic, jsonschema, and Hydra
20
+
21
+ ### Fixed
22
+ - `example_base.yaml` used `options:` for two attributes, but only `choices:` is actually validated; those keys are now `choices:` so the shipped example enforces its allowed values as documented
23
+ - Documentation audit: corrected the allowed-values key from `options` to `choices` throughout; documented the previously-undocumented `case_sensitive` key and the `tuple` type; fixed the non-runnable `MyConfig` example snippets (`super().__init__(basefile, userfile=...)` and a missing `import os`); replaced stale "Directive" terminology left from the 2.0.3 rename; added a Quickstart page and a worked `docs:` example; fleshed out the `config-help` page with sample output; and fixed assorted typos
24
+
8
25
  ## [2.2.0] - 2026-07-21
9
26
 
10
27
  ### Added
@@ -0,0 +1,167 @@
1
+ Metadata-Version: 2.5
2
+ Name: ycleptic
3
+ Version: 2.2.2
4
+ Summary: A YAML-format configuration generator
5
+ Project-URL: Source, https://github.com/cameronabrams/ycleptic
6
+ Project-URL: Documentation, https://ycleptic.readthedocs.io/en/latest/
7
+ Project-URL: Bug Tracker, https://github.com/cameronabrams/ycleptic/issues
8
+ Author-email: Cameron F Abrams <cfa22@drexel.edu>
9
+ License: MIT License
10
+
11
+ Copyright (c) 2022 Cameron Abrams
12
+
13
+ Permission is hereby granted, free of charge, to any person obtaining a copy
14
+ of this software and associated documentation files (the "Software"), to deal
15
+ in the Software without restriction, including without limitation the rights
16
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
17
+ copies of the Software, and to permit persons to whom the Software is
18
+ furnished to do so, subject to the following conditions:
19
+
20
+ The above copyright notice and this permission notice shall be included in all
21
+ copies or substantial portions of the Software.
22
+
23
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
24
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
26
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
28
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
29
+ SOFTWARE.
30
+ License-File: LICENSE
31
+ Classifier: License :: OSI Approved :: MIT License
32
+ Classifier: Operating System :: OS Independent
33
+ Classifier: Programming Language :: Python :: 3
34
+ Classifier: Programming Language :: Python :: 3.9
35
+ Classifier: Programming Language :: Python :: 3.10
36
+ Classifier: Programming Language :: Python :: 3.11
37
+ Classifier: Programming Language :: Python :: 3.12
38
+ Classifier: Programming Language :: Python :: 3.13
39
+ Requires-Python: >=3.9
40
+ Requires-Dist: pyyaml>=6
41
+ Provides-Extra: lint
42
+ Requires-Dist: mypy; extra == 'lint'
43
+ Requires-Dist: ruff==0.15.22; extra == 'lint'
44
+ Provides-Extra: test
45
+ Requires-Dist: pytest; extra == 'test'
46
+ Description-Content-Type: text/markdown
47
+
48
+ # Ycleptic
49
+ > Self-documenting YAML configuration for Python applications
50
+
51
+ [![PyPI](https://img.shields.io/pypi/v/ycleptic)](https://pypi.org/project/ycleptic/)
52
+ [![Python versions](https://img.shields.io/pypi/pyversions/ycleptic)](https://pypi.org/project/ycleptic/)
53
+ [![CI](https://github.com/cameronabrams/ycleptic/actions/workflows/ci.yaml/badge.svg)](https://github.com/cameronabrams/ycleptic/actions/workflows/ci.yaml)
54
+ [![Documentation Status](https://readthedocs.org/projects/ycleptic/badge/?version=latest)](https://ycleptic.readthedocs.io/en/latest/?badge=latest)
55
+ [![License: MIT](https://img.shields.io/pypi/l/ycleptic)](https://github.com/cameronabrams/ycleptic/blob/main/LICENSE)
56
+
57
+ One structured YAML file describes your application's configuration schema. From
58
+ that single source of truth, Ycleptic gives you three things that normally live
59
+ in three separate places:
60
+
61
+ 1. **Validation & defaults** — a user's YAML config is checked against the
62
+ schema (allowed keys, data types, `choices`, required values), and omitted
63
+ parameters are filled in from their declared defaults.
64
+ 2. **Generated documentation** — `yclept make-doc` builds an RST/Sphinx
65
+ documentation tree for your config directly from the schema.
66
+ 3. **Interactive help** — `yclept config-help` lets users explore the
67
+ configuration tree and read the help text for every parameter.
68
+
69
+ Because the schema is *data* — a YAML file you ship as package data, not a set of
70
+ Python classes — editing that one file keeps validation, documentation, and help
71
+ in lockstep. No more reference docs drifting out of date because you added a
72
+ parameter and forgot to write it up.
73
+
74
+ ## When to use it
75
+
76
+ Ycleptic fills a specific niche: it shines when your configuration's **schema
77
+ should double as its documentation**, and when your users benefit from
78
+ *exploring* that configuration interactively — a common situation in scientific
79
+ and command-line applications whose users are domain experts rather than
80
+ programmers.
81
+
82
+ It is intentionally **not** a heavyweight validation engine. If your main need is:
83
+
84
+ - **robust validation, coercion, and rich error messages** — reach for
85
+ [pydantic](https://docs.pydantic.dev/) or
86
+ [jsonschema](https://python-jsonschema.readthedocs.io/);
87
+ - **composable, hierarchical config with overrides and interpolation** — reach
88
+ for [Hydra / OmegaConf](https://hydra.cc/).
89
+
90
+ Ycleptic keeps validation deliberately lightweight and puts its weight behind the
91
+ spec-as-documentation workflow. (It also supports a per-user dotfile/rcfile that
92
+ extends or overrides the base config, merged in automatically at load time.)
93
+
94
+ ## How it works
95
+
96
+ As the developer, you write a **base config** that specifies what your users may
97
+ configure:
98
+
99
+ ```yaml
100
+ # mypackage/data/base.yaml
101
+ attributes:
102
+ - name: temperature
103
+ type: float
104
+ text: Simulation temperature in kelvin
105
+ default: 300.0
106
+ - name: integrator
107
+ type: str
108
+ text: Integration scheme to use
109
+ choices: [verlet, langevin]
110
+ default: verlet
111
+ ```
112
+
113
+ Your app reads the base config together with the user's config through the
114
+ `Yclept` class (typically subclassed):
115
+
116
+ ```python
117
+ from ycleptic import Yclept, YclepticError
118
+
119
+ try:
120
+ config = Yclept(basefile='mypackage/data/base.yaml', userfile=user_yaml)
121
+ except YclepticError as e:
122
+ raise SystemExit(f'Invalid configuration: {e}')
123
+ ```
124
+
125
+ Then, from the *same* base config, you can generate reference documentation:
126
+
127
+ ```bash
128
+ yclept make-doc mypackage/data/base.yaml --root docs/source/config_ref
129
+ ```
130
+
131
+ and your users can explore the configuration interactively:
132
+
133
+ ```bash
134
+ yclept config-help mypackage/data/base.yaml
135
+ ```
136
+
137
+ ## Installation
138
+
139
+ ```bash
140
+ pip install ycleptic
141
+ ```
142
+
143
+ ## Documentation
144
+
145
+ Full documentation is at <https://ycleptic.readthedocs.io/en/latest/>.
146
+
147
+ ## Release History
148
+
149
+ See [CHANGELOG.md](CHANGELOG.md) for the full release history.
150
+
151
+ ## Meta
152
+
153
+ Cameron F. Abrams – cfa22@drexel.edu
154
+
155
+ Distributed under the MIT license. See `LICENSE` for more information.
156
+
157
+ [https://github.com/cameronabrams](https://github.com/cameronabrams/)
158
+
159
+ [https://github.com/AbramsGroup](https://github.com/AbramsGroup/)
160
+
161
+ ## Contributing
162
+
163
+ 1. Fork it (<https://github.com/cameronabrams/ycleptic/fork>)
164
+ 2. Create your feature branch (`git checkout -b feature/fooBar`)
165
+ 3. Commit your changes (`git commit -am 'Add some fooBar'`)
166
+ 4. Push to the branch (`git push origin feature/fooBar`)
167
+ 5. Create a new Pull Request
@@ -0,0 +1,120 @@
1
+ # Ycleptic
2
+ > Self-documenting YAML configuration for Python applications
3
+
4
+ [![PyPI](https://img.shields.io/pypi/v/ycleptic)](https://pypi.org/project/ycleptic/)
5
+ [![Python versions](https://img.shields.io/pypi/pyversions/ycleptic)](https://pypi.org/project/ycleptic/)
6
+ [![CI](https://github.com/cameronabrams/ycleptic/actions/workflows/ci.yaml/badge.svg)](https://github.com/cameronabrams/ycleptic/actions/workflows/ci.yaml)
7
+ [![Documentation Status](https://readthedocs.org/projects/ycleptic/badge/?version=latest)](https://ycleptic.readthedocs.io/en/latest/?badge=latest)
8
+ [![License: MIT](https://img.shields.io/pypi/l/ycleptic)](https://github.com/cameronabrams/ycleptic/blob/main/LICENSE)
9
+
10
+ One structured YAML file describes your application's configuration schema. From
11
+ that single source of truth, Ycleptic gives you three things that normally live
12
+ in three separate places:
13
+
14
+ 1. **Validation & defaults** — a user's YAML config is checked against the
15
+ schema (allowed keys, data types, `choices`, required values), and omitted
16
+ parameters are filled in from their declared defaults.
17
+ 2. **Generated documentation** — `yclept make-doc` builds an RST/Sphinx
18
+ documentation tree for your config directly from the schema.
19
+ 3. **Interactive help** — `yclept config-help` lets users explore the
20
+ configuration tree and read the help text for every parameter.
21
+
22
+ Because the schema is *data* — a YAML file you ship as package data, not a set of
23
+ Python classes — editing that one file keeps validation, documentation, and help
24
+ in lockstep. No more reference docs drifting out of date because you added a
25
+ parameter and forgot to write it up.
26
+
27
+ ## When to use it
28
+
29
+ Ycleptic fills a specific niche: it shines when your configuration's **schema
30
+ should double as its documentation**, and when your users benefit from
31
+ *exploring* that configuration interactively — a common situation in scientific
32
+ and command-line applications whose users are domain experts rather than
33
+ programmers.
34
+
35
+ It is intentionally **not** a heavyweight validation engine. If your main need is:
36
+
37
+ - **robust validation, coercion, and rich error messages** — reach for
38
+ [pydantic](https://docs.pydantic.dev/) or
39
+ [jsonschema](https://python-jsonschema.readthedocs.io/);
40
+ - **composable, hierarchical config with overrides and interpolation** — reach
41
+ for [Hydra / OmegaConf](https://hydra.cc/).
42
+
43
+ Ycleptic keeps validation deliberately lightweight and puts its weight behind the
44
+ spec-as-documentation workflow. (It also supports a per-user dotfile/rcfile that
45
+ extends or overrides the base config, merged in automatically at load time.)
46
+
47
+ ## How it works
48
+
49
+ As the developer, you write a **base config** that specifies what your users may
50
+ configure:
51
+
52
+ ```yaml
53
+ # mypackage/data/base.yaml
54
+ attributes:
55
+ - name: temperature
56
+ type: float
57
+ text: Simulation temperature in kelvin
58
+ default: 300.0
59
+ - name: integrator
60
+ type: str
61
+ text: Integration scheme to use
62
+ choices: [verlet, langevin]
63
+ default: verlet
64
+ ```
65
+
66
+ Your app reads the base config together with the user's config through the
67
+ `Yclept` class (typically subclassed):
68
+
69
+ ```python
70
+ from ycleptic import Yclept, YclepticError
71
+
72
+ try:
73
+ config = Yclept(basefile='mypackage/data/base.yaml', userfile=user_yaml)
74
+ except YclepticError as e:
75
+ raise SystemExit(f'Invalid configuration: {e}')
76
+ ```
77
+
78
+ Then, from the *same* base config, you can generate reference documentation:
79
+
80
+ ```bash
81
+ yclept make-doc mypackage/data/base.yaml --root docs/source/config_ref
82
+ ```
83
+
84
+ and your users can explore the configuration interactively:
85
+
86
+ ```bash
87
+ yclept config-help mypackage/data/base.yaml
88
+ ```
89
+
90
+ ## Installation
91
+
92
+ ```bash
93
+ pip install ycleptic
94
+ ```
95
+
96
+ ## Documentation
97
+
98
+ Full documentation is at <https://ycleptic.readthedocs.io/en/latest/>.
99
+
100
+ ## Release History
101
+
102
+ See [CHANGELOG.md](CHANGELOG.md) for the full release history.
103
+
104
+ ## Meta
105
+
106
+ Cameron F. Abrams – cfa22@drexel.edu
107
+
108
+ Distributed under the MIT license. See `LICENSE` for more information.
109
+
110
+ [https://github.com/cameronabrams](https://github.com/cameronabrams/)
111
+
112
+ [https://github.com/AbramsGroup](https://github.com/AbramsGroup/)
113
+
114
+ ## Contributing
115
+
116
+ 1. Fork it (<https://github.com/cameronabrams/ycleptic/fork>)
117
+ 2. Create your feature branch (`git checkout -b feature/fooBar`)
118
+ 3. Commit your changes (`git commit -am 'Add some fooBar'`)
119
+ 4. Push to the branch (`git push origin feature/fooBar`)
120
+ 5. Create a new Pull Request
@@ -0,0 +1,46 @@
1
+ ycleptic
2
+ ========
3
+
4
+ |pypi| |pyversions| |ci| |docs| |license|
5
+
6
+ .. |pypi| image:: https://img.shields.io/pypi/v/ycleptic
7
+ :target: https://pypi.org/project/ycleptic/
8
+ :alt: PyPI version
9
+ .. |pyversions| image:: https://img.shields.io/pypi/pyversions/ycleptic
10
+ :target: https://pypi.org/project/ycleptic/
11
+ :alt: Supported Python versions
12
+ .. |ci| image:: https://github.com/cameronabrams/ycleptic/actions/workflows/ci.yaml/badge.svg
13
+ :target: https://github.com/cameronabrams/ycleptic/actions/workflows/ci.yaml
14
+ :alt: CI status
15
+ .. |docs| image:: https://readthedocs.org/projects/ycleptic/badge/?version=latest
16
+ :target: https://ycleptic.readthedocs.io/en/latest/?badge=latest
17
+ :alt: Documentation status
18
+ .. |license| image:: https://img.shields.io/pypi/l/ycleptic
19
+ :target: https://github.com/cameronabrams/ycleptic/blob/main/LICENSE
20
+ :alt: License: MIT
21
+
22
+ **Ycleptic** (ee-KLEP-tic) turns a single, structured YAML file into a self-documenting configuration system for your Python application. From one schema file you get three things at once: validation of a user's config (with defaults, allowed value ``choices``, and required parameters), an automatically generated RST/Sphinx documentation tree, and an interactive help explorer for your users. Because the schema is data rather than Python code, editing that one file keeps validation, documentation, and help in lockstep.
23
+
24
+ Ycleptic is intentionally lightweight on validation and focuses on the *spec-as-documentation* workflow — a good fit for scientific and command-line applications whose users are domain experts. If you need heavyweight validation and coercion, `pydantic <https://docs.pydantic.dev/>`_ or `jsonschema <https://python-jsonschema.readthedocs.io/>`_ are better suited; for composable, hierarchical config, see `Hydra <https://hydra.cc/>`_.
25
+
26
+ .. note::
27
+
28
+ Ycleptic is under active development.
29
+
30
+ .. note::
31
+
32
+ Ycleptic is used in the `pestifer <https://pypi.org/project/pestifer/>`_ package.
33
+
34
+ Contents
35
+ --------
36
+
37
+ .. toctree::
38
+ :maxdepth: 1
39
+
40
+ about
41
+ installation
42
+ usage
43
+ API <api/API>
44
+ roadmap
45
+ changelog
46
+
@@ -34,13 +34,14 @@ You then might like to create a "config" class for your package that inherits :c
34
34
 
35
35
  .. code-block:: python
36
36
 
37
+ import os
37
38
  from ycleptic.yclept import Yclept
38
39
  from mypackage import data # to get the path to your package data; there are other ways to do this
39
40
 
40
41
  class MyConfig(Yclept):
41
42
  def __init__(self, userconfigfile=''):
42
43
  basefile=os.path.join(os.path.dirname(data.__file__),"base.yaml") # your app's base config
43
- super().__init__(data.basefile,userconfigfile=userconfigfile)
44
+ super().__init__(basefile, userfile=userconfigfile)
44
45
 
45
46
 
46
47
  Here, ``data`` is just a directory where you store your package data (``rootdir/mypackage/data``, in the example), and you can put ``base.yaml`` in that directory as the base configuration description. Essentially, it is a description of **what** can be configured by a **user's** configuration file when **they** run your app. Now, inside your app source, if you want to read in the user's configuration file (like if its name was passed in as a command-line argument), you would instantiate a member of the ``MyConfig`` class:
@@ -3,19 +3,20 @@
3
3
  Interactive Help
4
4
  ===================
5
5
 
6
- The ``Yclept`` class has a method called ``console_help()`` that is meant to provides interactive help to a package user trying to develop their own config file that conform's to your package's base config.
6
+ The ``Yclept`` class has a method called ``console_help()`` that is meant to provide interactive help to a package user trying to develop their own config file that conforms to your package's base config.
7
7
 
8
8
  Suppose this is the content of ``config.py``:
9
9
 
10
10
  .. code-block:: python
11
11
 
12
+ import os
12
13
  from ycleptic.yclept import Yclept
13
14
  from mypackage import data
14
15
 
15
16
  class MyConfig(Yclept):
16
17
  def __init__(self, userconfigfile=''):
17
18
  basefile=os.path.join(os.path.dirname(data.__file__),"base.yaml")
18
- super().__init__(data.basefile,userconfigfile=userconfigfile)
19
+ super().__init__(basefile, userfile=userconfigfile)
19
20
 
20
21
 
21
22
  Here is an example of how the interactive help works:
@@ -36,7 +37,7 @@ This reflects the fact that the three top-level attributes available are called
36
37
 
37
38
  .. code-block:: console
38
39
 
39
- >>> Y.console_help([],interactive_prompt='help: ')
40
+ >>> c.console_help([],interactive_prompt='help: ')
40
41
  attribute_1 ->
41
42
  attribute_2 ->
42
43
  attribute_3 ->
@@ -45,7 +46,7 @@ This reflects the fact that the three top-level attributes available are called
45
46
  help: attribute_1
46
47
 
47
48
  attribute_1:
48
- This is a description of Directive 1
49
+ This is a description of Attribute 1
49
50
 
50
51
  base|attribute_1
51
52
  attribute_1_1
@@ -0,0 +1,72 @@
1
+ .. _usage_quickstart:
2
+
3
+ Quickstart
4
+ ==========
5
+
6
+ This is the smallest useful Ycleptic setup: define a base config, load a user
7
+ config against it, and generate documentation — all from one schema file.
8
+
9
+ 1. Write a base config
10
+ -----------------------------
11
+
12
+ The base config is a YAML file describing what your users may configure. Ship
13
+ it as package data, e.g. ``mypackage/data/base.yaml``:
14
+
15
+ .. code-block:: yaml
16
+
17
+ attributes:
18
+ - name: temperature
19
+ type: float
20
+ text: Simulation temperature in kelvin
21
+ default: 300.0
22
+ - name: integrator
23
+ type: str
24
+ text: Integration scheme to use
25
+ choices: [verlet, langevin]
26
+ default: verlet
27
+
28
+ 2. Load a user config
29
+ -----------------------------
30
+
31
+ Read the base config together with a user's config through
32
+ :class:`ycleptic.yclept.Yclept`. Omitted values are filled in from their
33
+ declared defaults; invalid values raise :class:`ycleptic.YclepticError`:
34
+
35
+ .. code-block:: python
36
+
37
+ from ycleptic import Yclept, YclepticError
38
+
39
+ try:
40
+ config = Yclept(basefile='mypackage/data/base.yaml', userfile='user.yaml')
41
+ except YclepticError as e:
42
+ raise SystemExit(f'Invalid configuration: {e}')
43
+
44
+ print(config['user']['temperature']) # 300.0 if the user omitted it
45
+
46
+ If ``user.yaml`` sets only the integrator:
47
+
48
+ .. code-block:: yaml
49
+
50
+ integrator: langevin
51
+
52
+ then ``config['user']`` becomes ``{'integrator': 'langevin', 'temperature':
53
+ 300.0}`` — the default temperature is supplied automatically.
54
+
55
+ 3. Generate documentation and explore
56
+ --------------------------------------------
57
+
58
+ From the *same* base config you can generate a Sphinx reference tree:
59
+
60
+ .. code-block:: console
61
+
62
+ $ yclept make-doc mypackage/data/base.yaml --root docs/source/config_ref
63
+
64
+ and let your users explore the configuration interactively:
65
+
66
+ .. code-block:: console
67
+
68
+ $ yclept config-help mypackage/data/base.yaml
69
+
70
+ The rest of this guide covers each piece in detail: :ref:`usage_the_base_config`,
71
+ :ref:`usage_the_user_config`, :ref:`usage_interactive_help`, and
72
+ :ref:`usage_yclept_makedoc`.
@@ -5,22 +5,22 @@ Resource File
5
5
 
6
6
  You may want users of your application to be able to set their own global default values for attributes, overwriting defaults you define in your application's base configuration. ``Yclept`` supports reading a secondary resource file (e.g., ``~/.your_app_name.rc``) in which users can specify attributes that replace or add to the list of attributes in your application's base configuration.
7
7
 
8
- For example, continuing with the base configuration defined above, suppose a user of your application has the file ``~/.your_app_name.rc`` with these contents:
8
+ For example, continuing with the base configuration from :ref:`usage_the_base_config`, suppose a user of your application has the file ``~/.your_app_name.rc`` with these contents:
9
9
 
10
10
  .. code-block:: yaml
11
11
 
12
12
  attributes:
13
13
  - name: attribute_2
14
14
  type: list
15
- text: Directive 2 is interpretable as an ordered list of attributes
15
+ text: Attribute 2 is interpretable as an ordered list of attributes
16
16
  attributes:
17
17
  - name: attribute_2a
18
18
  type: dict
19
- text: Directive 2a is one possible attribute in a user's list
19
+ text: Attribute 2a is one possible attribute in a user's list
20
20
  attributes:
21
21
  - name: d2a_val2
22
22
  type: int
23
- text: An int for Value 2 of Directive 2a
23
+ text: An int for Value 2 of Attribute 2a
24
24
  default: 7 # user has changed this in their resource file
25
25
 
26
26
  The presence of this file indicates the user would like the default value of attribute ``d2a_val2`` under attribute ``attribute_2a`` of base attribute ``attribute_2`` to be 7 instead of 6.
@@ -22,7 +22,7 @@ The heart of ``ycleptic`` is the base configuration file, which the app develope
22
22
  - name: attribute_1_2
23
23
  type: str
24
24
  text: This is a description of Attribute 1.2
25
- options: [ValA, ValB]
25
+ choices: [valA, valB]
26
26
  - name: attribute_2
27
27
  type: list
28
28
  text: Attribute 2 is interpretable as an ordered list of attributes
@@ -101,7 +101,7 @@ The heart of ``ycleptic`` is the base configuration file, which the app develope
101
101
  - name: flipaxis
102
102
  type: str
103
103
  text: Axis around which flip is performed
104
- options: ['x','y','z']
104
+ choices: ['x','y','z']
105
105
  - name: d322b
106
106
  type: dict
107
107
  text: Subattribute D 3.2.2b saves the result
@@ -114,7 +114,7 @@ The heart of ``ycleptic`` is the base configuration file, which the app develope
114
114
 
115
115
  The base config must open with the single identifier ``attributes``, under which is a list of one or more top-level attributes. Every attribute must have a declared type, and attributes can be nested.
116
116
 
117
- ``type`` can be one of ``int``, ``float``, ``str``, ``bool``, ``list``, or ``dict``. The data content in a attribute is of type ``type`` unless two conditions are met:
117
+ ``type`` can be one of ``int``, ``float``, ``str``, ``bool``, ``tuple``, ``list``, or ``dict``. The data content in an attribute is of type ``type`` unless two conditions are met:
118
118
 
119
119
  1. ``type`` is either ``list`` or ``dict``; and
120
120
  2. the keyword ``attributes`` is present.
@@ -123,9 +123,41 @@ In this case, there are subattributes. If the ``type`` was ``dict``, then the s
123
123
 
124
124
  ``text`` is just meant for helpful text describing the attribute, and it can be completely free-form as long as it is on one line or blocked multiline using ``|``.
125
125
 
126
- There are four other keys that a attribute may have:
126
+ There are several other keys an attribute may have:
127
127
 
128
- 1. ``default``: as you might expect, this are default values to assign to the attribute if the user "declares" the attribute but does not provide it any values.
129
- 2. ``required``: a boolean. If False, that means no defaults are assigned; if a user declares this attribute without providing values, an error occurs, but a user need not declare this attribute at all. If True, the attribute must be declared (and if it is nested, all the antecedant attributes must also be declared).
130
- 3. ``options``: a list of allowed values; if the user declares this attribute with a value not in this list, an error occurs.
131
- 4. ``docs``: this is a subattribute that can have ``title``, ``text``, and ``example`` keys. ``title`` and ``text`` are strings used in automatic documentation generation using ``yclept make-doc``. ``example`` is a YAML-format example of how to use the attribute in a config file. This is used in the documentation generation as well.
128
+ 1. ``default``: the default value (or values) assigned to the attribute when the user declares it but provides no value.
129
+ 2. ``required``: a boolean. If ``True``, the attribute must be declared (and if it is nested, all its antecedent attributes must be declared too). If ``False``, no defaults are assigned: the user need not declare the attribute at all, but declaring it without providing a value is an error.
130
+ 3. ``choices``: a list of allowed values; if the user gives a value that is not in the list, an error occurs. For ``str`` attributes the comparison honors ``case_sensitive`` (below).
131
+ 4. ``case_sensitive``: for ``str`` attributes only; a boolean that defaults to ``True``. When ``False``, the user's value is matched against ``choices`` case-insensitively and stored in casefolded (lower-case) form.
132
+ 5. ``docs``: a block that enriches the output of ``yclept make-doc``. It may contain ``title`` and ``text`` strings and a YAML-format ``example`` showing the attribute in use. See :ref:`base_config_docs_key` below.
133
+
134
+ .. _base_config_docs_key:
135
+
136
+ Enriching generated documentation with ``docs``
137
+ -------------------------------------------------
138
+
139
+ The ``text`` key gives every attribute a one-line description that appears in
140
+ interactive help and generated documentation. When you want richer, prose
141
+ documentation for an attribute — the kind you would write into a reference
142
+ manual — add a ``docs`` block. It is used only by ``yclept make-doc`` and is
143
+ ignored during configuration validation:
144
+
145
+ .. code-block:: yaml
146
+
147
+ - name: integrator
148
+ type: str
149
+ text: Integration scheme to use
150
+ choices: [verlet, langevin]
151
+ default: verlet
152
+ docs:
153
+ title: Integration scheme
154
+ text: |
155
+ Selects the time-integration algorithm. ``verlet`` is symplectic and
156
+ conserves energy well; ``langevin`` couples the system to a heat bath
157
+ and is appropriate for constant-temperature runs.
158
+ example:
159
+ integrator: langevin
160
+
161
+ ``title`` and ``text`` supply a heading and prose for the attribute's generated
162
+ page, and ``example`` is rendered as a YAML code block showing the attribute in
163
+ use. See :ref:`usage_yclept_makedoc` for how the tree is generated.
@@ -0,0 +1,41 @@
1
+ .. _usage_yclept_config_help:
2
+
3
+ ``yclept config-help``
4
+ ========================
5
+
6
+ The command-line tool ``yclept config-help <base.yaml>`` lets you use the interactive help feature detailed in :ref:`usage_interactive_help` to explore a base configuration file directly, without writing any code. For example, if you have a base configuration file called ``base.yaml``, you can run:
7
+
8
+ .. code-block:: console
9
+
10
+ $ yclept config-help base.yaml
11
+
12
+ which drops you into the interactive explorer:
13
+
14
+ .. code-block:: console
15
+
16
+ $ yclept config-help base.yaml
17
+ attribute_1 ->
18
+ attribute_2 ->
19
+ attribute_3 ->
20
+ .. up
21
+ ! quit
22
+ help: attribute_2
23
+
24
+ attribute_2:
25
+ Attribute 2 is interpretable as an ordered list of attributes
26
+
27
+ base|attribute_2
28
+ attribute_2a ->
29
+ attribute_2b ->
30
+ .. up
31
+ ! quit
32
+ help: !
33
+
34
+ At each prompt, type an attribute name to drill into it, ``..`` to go back up a
35
+ level, and ``!`` to quit. A trailing ``->`` marks an attribute that has
36
+ subattributes. You can also pass a space-separated attribute path on the
37
+ command line to jump straight to a node, for example:
38
+
39
+ .. code-block:: console
40
+
41
+ $ yclept config-help base.yaml attribute_2 attribute_2a
@@ -77,7 +77,7 @@ Each generated RST file ends with a footer whose appearance is controlled by
77
77
 
78
78
  ----
79
79
 
80
- This page was automatically generated by **ycleptic** v2.0.3 on 2025-09-04.
80
+ This page was automatically generated by **ycleptic** vX.Y.Z on YYYY-MM-DD.
81
81
 
82
82
  ``comment``
83
83
  An RST comment — present in the source but invisible in the rendered output.
@@ -3,9 +3,10 @@ Usage
3
3
 
4
4
  ``Ycleptic`` primarily exposes the :class:`ycleptic.yclept.Yclept` class to inherit in your own applications. It also has a command-line interface with two subcommands: ``yclept config-help`` and ``yclept make-doc``. The former provides interactive help for the configuration file, and the latter generates documentation from the base configuration file.
5
5
 
6
- .. toctree::
6
+ .. toctree::
7
7
  :maxdepth: 1
8
8
 
9
+ usage/quickstart
9
10
  usage/class
10
11
  usage/the_base_config
11
12
  usage/the_user_config
@@ -3,7 +3,7 @@ requires = ["hatchling"]
3
3
  build-backend = "hatchling.build"
4
4
  [project]
5
5
  name = "ycleptic"
6
- version = "2.2.0"
6
+ version = "2.2.2"
7
7
  authors = [
8
8
  { name="Cameron F Abrams", email="cfa22@drexel.edu" },
9
9
  ]
@@ -270,6 +270,42 @@ base|attribute_2->attribute_2a
270
270
  with open('console-out.txt', 'r') as f:
271
271
  self.assertEqual(f.read(), ref_str)
272
272
 
273
+ def test_console_help_eof_quits_cleanly(self):
274
+ """EOF on stdin ends an interactive help session as if the user typed '!'."""
275
+ from unittest.mock import patch
276
+
277
+ Y = Yclept(BFILE)
278
+ with open('console-out.txt', 'w') as f:
279
+ with redirect_stdout(f):
280
+ with patch('builtins.input', side_effect=EOFError):
281
+ Y.console_help([], interactive_prompt='help: ')
282
+ with open('console-out.txt', 'r') as f:
283
+ self.assertIn('! quit', f.read())
284
+
285
+ def test_console_help_eof_after_bad_choice_quits_cleanly(self):
286
+ """EOF also ends the session from the re-prompt after an unrecognized choice."""
287
+ from unittest.mock import patch
288
+
289
+ Y = Yclept(BFILE)
290
+ with open('console-out.txt', 'w') as f:
291
+ with redirect_stdout(f):
292
+ with patch('builtins.input', side_effect=['bogus', EOFError]):
293
+ Y.console_help([], interactive_prompt='help: ')
294
+ with open('console-out.txt', 'r') as f:
295
+ self.assertIn('bogus not recognized.', f.read())
296
+
297
+ def test_console_help_keyboard_interrupt_quits_cleanly(self):
298
+ """Ctrl-C at the prompt ends the session cleanly rather than raising."""
299
+ from unittest.mock import patch
300
+
301
+ Y = Yclept(BFILE)
302
+ with open('console-out.txt', 'w') as f:
303
+ with redirect_stdout(f):
304
+ with patch('builtins.input', side_effect=KeyboardInterrupt):
305
+ Y.console_help([], interactive_prompt='help: ')
306
+ with open('console-out.txt', 'r') as f:
307
+ self.assertIn('! quit', f.read())
308
+
273
309
  def test_makedoc(self):
274
310
  Y = Yclept(BFILE)
275
311
  Y.make_doctree('ydoc')
@@ -328,6 +364,15 @@ Subattributes:
328
364
  Y = Yclept(BFILE, userfile='example1.yaml')
329
365
  self.assertEqual(Y['user']['attribute_5'], 'b')
330
366
 
367
+ def test_choices_case_sensitive_invalid(self):
368
+ """A value outside a case-sensitive attribute's choices is rejected."""
369
+ # attribute_1_2 has choices [valA, valB] and is case-sensitive by default,
370
+ # so 'ValA' (wrong case) must be rejected.
371
+ with open('example1.yaml', 'w') as f:
372
+ f.write('attribute_1:\n attribute_1_2: ValA\n')
373
+ with self.assertRaises(YclepticError):
374
+ Yclept(BFILE, userfile='example1.yaml')
375
+
331
376
  def test_choices_invalid(self):
332
377
  """attribute_5 rejects a value not in its choices list."""
333
378
  with open('example1.yaml', 'w') as f:
@@ -26,7 +26,7 @@ attributes:
26
26
  - name: attribute_1_2
27
27
  type: str
28
28
  text: This is a description of Attribute 1.2
29
- options: [ValA, ValB]
29
+ choices: [valA, valB]
30
30
  - name: attribute_2
31
31
  type: list
32
32
  text: Attribute 2 is interpretable as an ordered list of attributes
@@ -105,7 +105,7 @@ attributes:
105
105
  - name: flipaxis
106
106
  type: str
107
107
  text: Axis around which flip is performed
108
- options: ['x','y','z']
108
+ choices: ['x','y','z']
109
109
  - name: d322b
110
110
  type: dict
111
111
  text: Subattribute D 3.2.2b saves the result
@@ -201,23 +201,32 @@ class Yclept(UserDict):
201
201
  c = ''
202
202
  H.write_func(f' {m}{c}{a}')
203
203
 
204
+ def _prompt_choice(self):
205
+ H: Namespace = self.H
206
+ choice = '!'
207
+ if H.interactive_prompt != '':
208
+ try:
209
+ choice = input(H.interactive_prompt)
210
+ except (EOFError, KeyboardInterrupt):
211
+ # no more input, or the user interrupted; quit as though
212
+ # the user had typed '!'
213
+ H.write_func('')
214
+ choice = '!'
215
+ return choice
216
+
204
217
  def _get_help_choice(self, init_list: list[str]):
205
218
  H: Namespace = self.H
206
219
  if len(init_list) > 0:
207
220
  choice = init_list.pop()
208
221
  else:
209
- choice = '!'
210
- if H.interactive_prompt != '':
211
- choice = input(H.interactive_prompt)
222
+ choice = self._prompt_choice()
212
223
  while choice == '' or choice not in [x['name'] for x in H.base] + ['..', '!']:
213
224
  if choice != '':
214
225
  H.write_func(f'{choice} not recognized.')
215
226
  if len(init_list) > 0:
216
227
  choice = init_list.pop()
217
228
  else:
218
- choice = '!'
219
- if H.interactive_prompt != '':
220
- choice = input(H.interactive_prompt)
229
+ choice = self._prompt_choice()
221
230
  return choice
222
231
 
223
232
  def _help(self):
ycleptic-2.2.0/PKG-INFO DELETED
@@ -1,88 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: ycleptic
3
- Version: 2.2.0
4
- Summary: A YAML-format configuration generator
5
- Project-URL: Source, https://github.com/cameronabrams/ycleptic
6
- Project-URL: Documentation, https://ycleptic.readthedocs.io/en/latest/
7
- Project-URL: Bug Tracker, https://github.com/cameronabrams/ycleptic/issues
8
- Author-email: Cameron F Abrams <cfa22@drexel.edu>
9
- License: MIT License
10
-
11
- Copyright (c) 2022 Cameron Abrams
12
-
13
- Permission is hereby granted, free of charge, to any person obtaining a copy
14
- of this software and associated documentation files (the "Software"), to deal
15
- in the Software without restriction, including without limitation the rights
16
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
17
- copies of the Software, and to permit persons to whom the Software is
18
- furnished to do so, subject to the following conditions:
19
-
20
- The above copyright notice and this permission notice shall be included in all
21
- copies or substantial portions of the Software.
22
-
23
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
24
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
26
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
28
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
29
- SOFTWARE.
30
- License-File: LICENSE
31
- Classifier: License :: OSI Approved :: MIT License
32
- Classifier: Operating System :: OS Independent
33
- Classifier: Programming Language :: Python :: 3
34
- Classifier: Programming Language :: Python :: 3.9
35
- Classifier: Programming Language :: Python :: 3.10
36
- Classifier: Programming Language :: Python :: 3.11
37
- Classifier: Programming Language :: Python :: 3.12
38
- Classifier: Programming Language :: Python :: 3.13
39
- Requires-Python: >=3.9
40
- Requires-Dist: pyyaml>=6
41
- Provides-Extra: lint
42
- Requires-Dist: mypy; extra == 'lint'
43
- Requires-Dist: ruff==0.15.22; extra == 'lint'
44
- Provides-Extra: test
45
- Requires-Dist: pytest; extra == 'test'
46
- Description-Content-Type: text/markdown
47
-
48
- # Ycleptic
49
- > YAML configuration generator
50
-
51
- YAML is a popular markup language for input files, with its easy syntax and clear
52
- mapping to lists and dicts. Ycleptic allows a developer to specify all keys, datatypes,
53
- default values, choice restrictions, and other features of YAML-format input
54
- files for use in their own apps. This makes the specification of input file syntax on top
55
- of YAML for any particular application a bit easier than just using pure YAML. In addition,
56
- ycleptic can also automatically build the RST/Sphinx doctree for your app's configuration
57
- file.
58
-
59
- ## Installation
60
-
61
- ```bash
62
- pip install ycleptic
63
- ```
64
-
65
- Once installed, the developer has access to the ``Yclept`` class.
66
-
67
- ## Release History
68
-
69
- See [CHANGELOG.md](CHANGELOG.md) for the full release history.
70
-
71
- ## Meta
72
-
73
- Cameron F. Abrams – cfa22@drexel.edu
74
-
75
- Distributed under the MIT license. See ``LICENSE`` for more information.
76
-
77
- [https://github.com/cameronabrams](https://github.com/cameronabrams/)
78
-
79
- [https://github.com/AbramsGroup](https://github.com/AbramsGroup/)
80
-
81
- ## Contributing
82
-
83
- 1. Fork it (<https://github.com/cameronabrams/ycleptic/fork>)
84
- 2. Create your feature branch (`git checkout -b feature/fooBar`)
85
- 3. Commit your changes (`git commit -am 'Add some fooBar'`)
86
- 4. Push to the branch (`git push origin feature/fooBar`)
87
- 5. Create a new Pull Request
88
-
ycleptic-2.2.0/README.md DELETED
@@ -1,41 +0,0 @@
1
- # Ycleptic
2
- > YAML configuration generator
3
-
4
- YAML is a popular markup language for input files, with its easy syntax and clear
5
- mapping to lists and dicts. Ycleptic allows a developer to specify all keys, datatypes,
6
- default values, choice restrictions, and other features of YAML-format input
7
- files for use in their own apps. This makes the specification of input file syntax on top
8
- of YAML for any particular application a bit easier than just using pure YAML. In addition,
9
- ycleptic can also automatically build the RST/Sphinx doctree for your app's configuration
10
- file.
11
-
12
- ## Installation
13
-
14
- ```bash
15
- pip install ycleptic
16
- ```
17
-
18
- Once installed, the developer has access to the ``Yclept`` class.
19
-
20
- ## Release History
21
-
22
- See [CHANGELOG.md](CHANGELOG.md) for the full release history.
23
-
24
- ## Meta
25
-
26
- Cameron F. Abrams – cfa22@drexel.edu
27
-
28
- Distributed under the MIT license. See ``LICENSE`` for more information.
29
-
30
- [https://github.com/cameronabrams](https://github.com/cameronabrams/)
31
-
32
- [https://github.com/AbramsGroup](https://github.com/AbramsGroup/)
33
-
34
- ## Contributing
35
-
36
- 1. Fork it (<https://github.com/cameronabrams/ycleptic/fork>)
37
- 2. Create your feature branch (`git checkout -b feature/fooBar`)
38
- 3. Commit your changes (`git commit -am 'Add some fooBar'`)
39
- 4. Push to the branch (`git push origin feature/fooBar`)
40
- 5. Create a new Pull Request
41
-
@@ -1,5 +0,0 @@
1
- # Changelog
2
-
3
- ```{include} ../../CHANGELOG.md
4
- :heading-offset: 1
5
- ```
@@ -1,26 +0,0 @@
1
- ycleptic
2
- ========
3
-
4
- **Ycleptic** (ee-KLEP-tic) is a Python tool for facilitating the definition of YAML-format input files. It allows for specification of default values and value choices. It allows for fully nested dictionary/list structures for detailed input file organization.
5
-
6
- .. note::
7
-
8
- Ycleptic is under active development.
9
-
10
- .. note::
11
-
12
- Ycleptic is used in the `pestifer <https://pypi.org/project/pestifer/>`_ package.
13
-
14
- Contents
15
- --------
16
-
17
- .. toctree::
18
- :maxdepth: 1
19
-
20
- about
21
- installation
22
- usage
23
- API <api/API>
24
- roadmap
25
- changelog
26
-
@@ -1,10 +0,0 @@
1
- .. _usage_yclept_config_help:
2
-
3
- ``yclept config-help``
4
- ========================
5
-
6
- The command-line tool `yclept config-help <base.yaml>` allow you to use the interactive help feature detailed in :ref:`usage_interactive_help` to explore a base configuration file. For example, if you have a base configuration file called `base.yaml`, you can run the following command:
7
-
8
- .. code-block:: console
9
-
10
- $ yclept config-help base.yaml
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes