https://github.com/whyolet/jonf-py
JONF parser/formatter in Python
https://github.com/whyolet/jonf-py
configuration dsl jonf json parser python
Last synced: 6 months ago
JSON representation
JONF parser/formatter in Python
- Host: GitHub
- URL: https://github.com/whyolet/jonf-py
- Owner: whyolet
- License: mit
- Archived: true
- Created: 2022-04-15T11:30:19.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2025-09-12T16:08:37.000Z (10 months ago)
- Last Synced: 2025-09-25T04:43:54.082Z (9 months ago)
- Topics: configuration, dsl, jonf, json, parser, python
- Language: Python
- Size: 13.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# JONF parser/formatter in Python
> [!WARNING]
> JONF.py draft is **archived** in favor of [TTT](https://github.com/whyolet/ttt) - please check it.
NOTE: This is an early alpha version
- JONF format [docs](https://github.com/whyolet/jonf)
- Formatter is implemented and [tested](https://github.com/whyolet/jonf-py/blob/main/tests/test_format.py)
- Parser is not implemented yet
- Python example:
```python
# pip install jonf
import jonf, textwrap
text = textwrap.dedent(
"""\
compare =
- true
= true
"""
).rstrip()
data = {
"compare": [
"true",
True,
]
}
# TODO:
# assert jonf.parse(text) == data
assert jonf.format(data) == text
print(jonf.format(data))
```
Output:
```
compare =
- true
= true
```