Skip to main content

Security-focused modular developer multi-tool CLI.

Project description

Developer Utility Toolkit

CI Security GHCR Coverage

Security-focused, modular, format-aware Python CLI for common developer tasks.

Features

  • Automatic input detection for text, JSON, XML, Base64, URL, and file extension types
  • Direct format conversion using a plugin-based transformer registry
  • JSON and XML formatting, minification, and validation
  • Encoding tools (Base64 and URL encode/decode)
  • Binary/Hex/Text/Base64 conversion utilities
  • Interactive conversion mode (choose format by number/letter and print all direct outputs)
  • Image pixelation utility (optional pillow)
  • Sitemap generator and sitemap fetcher with URL validation and request timeouts
  • Local command history (~/.developer_utility_toolkit/history/history.jsonl)

Architecture

  • src/toolkit/core: abstractions, registry, detector, and safe I/O helpers
  • src/toolkit/transformers: pluggable one-step transformers
  • src/toolkit/formatters: JSON/XML format/minify/validate services
  • src/toolkit/image_tools: image utilities
  • src/toolkit/web_tools: sitemap generation/fetching
  • src/toolkit/history: local history service
  • src/toolkit/cli.py: Typer entrypoint and command wiring

Design choices:

  • No chained transformations by default (one direct transform per request target)
  • Safe XML parsing via defusedxml
  • Controlled output writes via sanitized filename + output directory constraints
  • Clear failure modes with explicit non-zero exit codes

Installation

Install from PyPI:

python -m pip install --upgrade pip
pip install developer-utility-toolkit

Install with all optional features:

pip install "developer-utility-toolkit[all]"

Install isolated with pipx (recommended for CLI tools):

pipx install developer-utility-toolkit

Docker (Alternative Install)

Install via GitHub Packages container (GHCR):

docker pull ghcr.io/artenisalija/developer-utility-kit:latest

Run help:

docker run --rm ghcr.io/artenisalija/developer-utility-kit:latest --help

Run a command with mounted files:

docker run --rm -v "$PWD:/work" -w /work ghcr.io/artenisalija/developer-utility-kit:latest format --kind json --file input.json --output output.json

Install developer tooling:

pip install ".[all,dev]"

Usage

toolkit analyze --text '{"name":"dev"}'
toolkit convert --from text --to base64 --text "hello"
toolkit convert-all --text "hello" --from text
toolkit convert-all --text "hello" --ask
toolkit interactive
# interactive now asks:
# 1) input format
# 2) conversion mode (all, one, or multiple targets)
# 3) value to convert
toolkit hash-all --text "hello"
toolkit hash-all --text "01101000 01101001" --from binary
toolkit format --kind json --text '{"b":2,"a":1}'
toolkit validate --kind xml --text '<root><a>1</a></root>'
toolkit minify --kind json --text '{"b":2,"a":1}'
toolkit image pixelate --input-file ./input.png --output-name output.png
toolkit sitemap generate --base-url https://example.com --path / --path /docs
toolkit sitemap fetch --url https://example.com/sitemap.xml
toolkit recent show --limit 10

Security Philosophy

  • Secure defaults and explicit input validation
  • Defused XML parser to prevent XXE/entity expansion attacks
  • No eval/exec usage
  • Timeout-controlled network calls
  • Sanitized output file names with constrained output directories
  • Graceful errors with explicit status codes

Development

Run local quality gates:

ruff check .
black --check .
mypy src tests
pytest
bandit -r src -ll
pip-audit --strict
safety check --full-report

Pre-commit:

pre-commit install
pre-commit run --all-files

CI/CD

  • ci.yml: lint + format + mypy + tests + coverage (>=85%) on Python 3.11/3.12
  • security.yml: Bandit + pip-audit + Safety
  • release.yml: runs on version tags (v*.*.*), builds wheel/sdist, runs tests, publishes to PyPI, creates GitHub release notes
  • ghcr.yml: builds and publishes multi-arch Docker images to GHCR (ghcr.io/artenisalija/developer-utility-kit)
  • Dependabot enabled for Python packages and GitHub Actions

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

developer_utility_toolkit-0.1.4.tar.gz (20.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

developer_utility_toolkit-0.1.4-py3-none-any.whl (21.6 kB view details)

Uploaded Python 3

File details

Details for the file developer_utility_toolkit-0.1.4.tar.gz.

File metadata

File hashes

Hashes for developer_utility_toolkit-0.1.4.tar.gz
Algorithm Hash digest
SHA256 7241d78bd53fa8e2dd991909738358069d02b9561e47f61eb04efa2b15aea2d5
MD5 46744df5d66daf2eec56cc8377bb5c63
BLAKE2b-256 f1accd2fc4d19e645749c08ea7c4a4c1adafb73ae035b5c9eb2e6c424b7080bf

See more details on using hashes here.

File details

Details for the file developer_utility_toolkit-0.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for developer_utility_toolkit-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 09efb5343b8536a2a7054e6f8cfaab6eb29caabc82526de5da0992171f6c65b7
MD5 a939ff54b7b05fa62b595983b8c389ff
BLAKE2b-256 cd4278303d5fb43a542ecb92e4777c7fb183001e216647d6f9eeab71d9034e73

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page