niet
A command-line tool to work with YAML, JSON, and TOML files.
What it is and what it does
Niet is a shell-friendly command-line tool for reading and querying YAML, JSON, and TOML files. It uses jmespath-style path expressions to extract nested values and supports multiple output formats (JSON, YAML, TOML, eval-safe strings, quoted variants, and delimited lists). You can pipe data from stdin, read from local files, or fetch from web URLs, making it useful for CI pipelines and shell scripts that need to parse configuration or data files without writing custom parsing code.
The tool is designed as a shell equivalent to jq or xmllint but for structured data formats. It can extract single values, filter lists, convert between formats, and output results in formats suitable for shell eval or environment variable assignment. Dependencies are minimal (jmespath, pytoml, pyyaml) and it installs as a pure Python wheel with low friction.
Use it for:
- Extract configuration values from YAML or JSON files in CI/CD pipelines and assign them to shell variables.
- Convert YAML configuration to JSON or TOML for use by tools that expect a different format.
- Query nested data structures from stdin in shell one-liners without writing custom parsing scripts.
- Filter and extract list elements from config files with output formatted for shell eval or IFS-based processing.
- Read and parse remote configuration files from web URLs directly in shell scripts.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
A command-line tool that extracts and transforms data from YAML, JSON, and TOML files using path expressions, with support for format conversion and shell integration.
No. While niet is low-friction to install and has no known vulnerabilities, it is abandoned with no maintenance or security updates forthcoming. For active projects, consider maintained alternatives; for existing scripts already using niet, it remains functional but carries the risk of unpatched issues.
Install
niet on PyPI
pip
pip install nietuv
uv add nietpoetry
poetry add nietInstalling niet
Before you install
Low install friction with a pure Python wheel and three lightweight dependencies (jmespath, pytoml, pyyaml). However, the package is abandoned—last release was 2023-04-21, so no maintenance or security updates are forthcoming.
License in practice
MIT license is permissive, allowing use in commercial and open-source projects with minimal restrictions; you must include a copy of the license and copyright notice.
Quickstart
pip install niet
echo '{"project": {"name": "my-app"}}' | niet project.name
# Output: my-app
niet project.name /path/to/file.json
Requires Python 3.9 or higher.
Verify before relying
- Whether jmespath expression support is complete or has known limitations beyond what the description states.
- Whether web resource reading (mentioned in description) is fully functional or has known issues.
- Current status of any open issues or pull requests in the repository.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 3 — jmespath, pytoml, pyyaml |
| Maintenance | abandoned — 1,211 days since the last release |
| First released | |
| Downloads | 294,806/month — #7,940 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: niet-3.2.0-py3-none-any.whl
Tags
More Software Development packages
Provides backported and experimental type hints…
permissive · top 100 on PyPI
numpyNumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
annotated-docProvides a way to document function parameters,…
permissive · top 100 on PyPI
typerTyper builds command-line applications from…
permissive · top 1,000 on PyPI
distlibDistlib provides low-level packaging utilities…
permissive · top 1,000 on PyPI
jmespathJMESPath is a query language for extracting and…
permissive · top 100 on PyPI
parse-errorsWraps parse and validation errors from JSON,…
permissive · top 15,000 on PyPI
shyamlCommand-line tool for querying and extracting…
permissive · top 5,000 on PyPI
toml-cliCommand-line tool for reading, writing, and…
permissive · top 15,000 on PyPI
yqyq is a command-line processor that applies jq…
permissive · top 5,000 on PyPI
yamllintyamllint checks YAML files for syntax errors,…
copyleft · top 1,000 on PyPI
pytest-variablesA pytest plugin that loads test variables from…
copyleft · top 15,000 on PyPI
objectpathObjectPath is a query language for finding and…
permissive · top 15,000 on PyPI
parselParsel extracts data from HTML, JSON, and XML…
permissive · top 5,000 on PyPI
yamlpathQuery, retrieve, update, merge, validate, and…
permissive · top 15,000 on PyPI