https://github.com/davideferigato/lumix
Modular, multilingual CLI converter for 30+ units: temperature, currency, base, weight, length, volume, area, speed, time, energy, pressure, power, data, bitrate, hash, color, IP tools, timezones, date, calendar, age, passwords, country, language, unit symbols, Roman numerals, Morse code, spoken numbers, NATO. Supports 5 languages, Docker, ...
https://github.com/davideferigato/lumix
bash-completion cli converter docker multilingual pytest python
Last synced: about 1 month ago
JSON representation
Modular, multilingual CLI converter for 30+ units: temperature, currency, base, weight, length, volume, area, speed, time, energy, pressure, power, data, bitrate, hash, color, IP tools, timezones, date, calendar, age, passwords, country, language, unit symbols, Roman numerals, Morse code, spoken numbers, NATO. Supports 5 languages, Docker, ...
- Host: GitHub
- URL: https://github.com/davideferigato/lumix
- Owner: davideFerigato
- License: mit
- Created: 2025-08-01T21:58:05.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2026-06-16T00:59:04.000Z (about 1 month ago)
- Last Synced: 2026-06-16T02:23:46.866Z (about 1 month ago)
- Topics: bash-completion, cli, converter, docker, multilingual, pytest, python
- Language: Python
- Homepage: https://davideferigato.github.io/Lumix/
- Size: 3.4 MB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
- Roadmap: ROADMAP.md
Awesome Lists containing this project
README
One CLI to convert everything β from temperature to Morse code, in 5 languages.
**Lumix** is a **modular**, **multilingual** command-line converter for physical units, digital data, time, security tools, and creative utilities.
Designed to be **easily extensible**, it features **shell autocompletion** β all in one sleek package.
π **Supported languages:** English, Italian, French, Spanish, Japanese.
βοΈ **Modular core:** add your own converters in minutes.
## π Table of contents
- [β¨ Features](#-features)
- [π€ Why Lumix?](#-why-lumix-instead-of-units-or-qalc)
- [π§± Architecture overview](#-architecture-overview)
- [π¦ Installation](#-installation)
- [π Basic Usage](#-basic-usage)
- [π Complete converter reference (30+ categories)](#-complete-converter-reference-30-categories)
- [β© Shell Autocompletion](#-shell-autocompletion)
- [π³ Docker](#-docker)
- [π§ͺ Testing](#-testing)
- [π Acknowledgements](#-acknowledgements)
---
## β¨ Features
- **π Multilingual by design** β Use Lumix in your native language (en, it, fr, es, jp).
- **π§© Modular architecture** β Each converter is independent; adding a new one is as simple as creating a new folder.
- **π Rich set of converters** β From physical units to digital data, from time zones to creative tools (see [reference table](#-complete-converter-reference-30-categories)).
- **β¨οΈ Shell autocompletion** β Works with bash and zsh via `argcomplete`.
- **π³ Dockerβready** β Run Lumix anywhere without installing dependencies.
- **π§ͺ Fully tested** β High test coverage with `pytest`.
---
## π€ Why Lumix instead of `units` or `qalc`?
| Feature | Lumix | GNU Units | qalc |
|---------|-------|-----------|------|
| Multilingual CLI (5 languages) | β
| β | β |
| 30+ categories out of the box | β
| β
| β
|
| Shell autocompletion | β
(argcomplete) | β | β |
| Modular, add your own converter in 5 min | β
| β | β |
| Docker image with 0 config | β
| β | β |
| Native hashing, IP tools, Morse | β
| β | β |
| Open source, Python, easily hackable | β
| β | β |
Lumix is **not** just another unit converter β it's a **pluggable framework** for CLI conversions, designed to be extended by developers and used by anyone in their native language.
---
## π§± Architecture overview
```mermaid
flowchart TD
User[User types: lumix en currency from EUR to USD 50]
CLI[cli.py + argcomplete]
Dispatcher[cli/main.py: parses lang and module name]
Parser[currency/parser.py: localizes keywords]
Convert[currency/convert.py: calls API/cache]
Output[Formatted result printed]
User --> CLI
CLI --> Dispatcher
Dispatcher --> Parser
Parser --> Convert
Convert --> Output
```
*Every converter follows the same pattern: `parser.py` β `convert.py` β output.*
---
## π¦ Installation
### From PyPI (recommended)
```bash
pip install lumix
```
### From source
```bash
git clone https://github.com/davideFerigato/lumix.git
cd lumix
python -m venv venv && source venv/bin/activate # or `venv\Scripts\activate` on Windows
pip install --upgrade pip
pip install -e .
```
---
## π Basic Usage
```bash
lumix --help
```
Lumix follows a simple pattern:
```bash
lumix from to
```
For example:
```bash
lumix en temperature from C to F 36.5
lumix it temperatura da C a F 36,5 # Italian uses comma as decimal separator
```
---
## π Complete converter reference (30+ categories)
| Category | Example command | Input units | Output units |
|----------|----------------|-------------|---------------|
| Temperature | `lumix en temperature from C to F 36.5` | C, F, K | C, F, K |
| Currency | `lumix en currency from EUR to USD 50` | EUR, USD, GBP, JPY, ... | EUR, USD, GBP, JPY, ... |
| Number bases | `lumix en base from dec to hex 255` | dec, bin, hex, oct | dec, bin, hex, oct |
| Weight | `lumix en weight from kg to lb 75` | kg, lb, oz, g, mg, st, t | same |
| Length | `lumix en length from m to ft 1.80` | m, km, cm, mm, mi, yd, ft, in, nmi | same |
| Volume | `lumix en volume from l to gal 2` | l, ml, m3, gal, qt, pt, cup, fl oz | same |
| Area | `lumix en area from m2 to ft2 50` | m2, km2, ft2, mi2, ha, acre, cm2, mm2, yd2, in2 | same |
| Speed | `lumix en speed from km/h to mph 130` | km/h, mph, m/s, kn | same |
| Time | `lumix en time from days to hours 3` | s, min, h, d, w | same |
| Energy | `lumix en energy from J to kcal 500` | J, kJ, cal, kcal, Wh, kWh, eV | same |
| Pressure | `lumix en pressure from bar to psi 2` | Pa, bar, atm, mmHg, psi | same |
| Power | `lumix en power from W to hp 1000` | W, kW, hp | same |
| Digital Data | `lumix en data from MB to GB 1500` | B, KB, MB, GB, TB | same |
| Bitrate | `lumix en bitrate from Mbps to Kbps 100` | bps, kbps, Mbps, Gbps, Tbps | same |
| Hash | `lumix en hash sha256 "hello world"` | md5, sha1, sha224, sha256, sha384, sha512 | hash string |
| Color | `lumix en color from rgb to hex 255,255,255` | rgb, hex | rgb, hex |
| IP Tools | `lumix en iptools cidr-to-range 192.168.1.0/24` | CIDR, IP, binary | range, binary, netmask, etc. |
| Time Zones | `lumix en timezones from Europe/Rome to Asia/Tokyo "2025-08-02 14:00"` | any IANA timezone | any IANA timezone |
| Date | `lumix en date from us to iso 08/02/2025` | us, iso, eu, jp | us, iso, eu, jp |
| Calendar | `lumix en calendar diff 2025-01-01 2025-12-31` | YYYY-MM-DD | days |
| Age | `lumix en age from 1990-05-23` | YYYY-MM-DD | years |
| Passwords | `lumix en passwords generate length 16 symbols true` | length, symbols flag | random password |
| Country | `lumix en country from code to name IT` | country code | country name |
| Language | `lumix en language from name to code "Italian"` | language name | ISO code |
| Unit Symbols | `lumix en unitsymbols from W to "unit name"` | symbol or name | symbol, name, type |
| Roman | `lumix en roman from 2025` | 1β3999 | Roman numeral |
| Morse | `lumix en morse to-text "... --- ..."` | text or Morse | text or Morse |
| Timezone Bot | `lumix en timezonebot what-time Tokyo` | city name | current local time |
| Spoken | `lumix en spoken from 123456` | integer | number in words (en/it) |
| Phonetic | `lumix en phonetic for CIAO` | text | NATO phonetic alphabet |
---
## β© Shell Autocompletion
Lumix integrates with `argcomplete` to provide smart tab completion.
```bash
pip install argcomplete
eval "$(register-python-argcomplete lumix)"
# Add the eval line to your ~/.bashrc or ~/.zshrc to make it permanent
```
> **Note:** Autocompletion is still under active improvement.
---
## π³ Docker
Run Lumix in a container without any local installation:
```bash
docker build -t lumix .
docker run --rm lumix en temperature from C to F 36.5
```
---
## π§ͺ Testing
We use `pytest` for unit tests. To run the full suite:
```bash
pytest tests/
```
Each module has its own test file (`test_.py`) to ensure reliability.
---
## π Acknowledgements
- [Frankfurter API](https://frankfurter.dev) for realβtime exchange rates.
- [argcomplete](https://github.com/kislyuk/argcomplete) for shell completion magic.