Privex-curconv

Latest version: v0.5.0

Safety actively analyzes 681775 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

0.5.0

Application

- Currently only one currency adapter, which uses the public `https://api.ratesapi.io/api` API. The codebase has been designed for easily adding new adapters at a later point, but for now, the RatesAPI is the only adapter and there's no way for a user to change it without editing the code.

- Support for direct conversions, i.e. `5 usd to gbp`

- Support for conversion lists/favourites, i.e. `10 gbp` outputs the rate in USD, EUR, SEK, TRY, etc.
- Support for printing all available rates using `-a`

- Support for customising the decimal places with `-d` / `-dp` / `--dp`

- Support for generating a `.env` file, and automatically creating it for you via the `-Gd` flag

- A wide variety of settings are adjustable by the user via either ENV vars, CLI arguments, or both.

- Support for caching the exchange rates via all supported [privex-helpers](https://github.com/Privex/python-helpers) AsyncIO cache modules, with SQLite being used by default due to it's persistance without reliance on a background service. The adapter can be changed to `memcached` or `redis` using the `CACHE_ADAPTER` env var.

- Standard mode prints out just a rate when you do `conv 5 usd to gbp` which is useful for scripting, while you can also use full mode via `conv -f 5 usd to gbp` which will display more friendly `5.000 USD = 4.382 GBP` etc.

- Can be ran via both the binary `conv`, or through python's module runner `python3 -m privex.curconv`

- Many more features :)

Distribution

- Included PYZ compiler script `compile.sh` for compiling the app into a self-contained PYZ executable (only usable on Linux/Mac/UNIX systems). The latest PYZ is attached.

- Published to PyPi with both a wheel and source distribution. Additionally, a PYZ binary is attached in this release for download.

Using the PYZ

sh
Download + make executable
wget -O /usr/local/bin/conv https://github.com/Privex/python-curconv/releases/download/0.5.0/conv.pyz
chmod +x /usr/local/bin/conv
And you're ready to use it!
conv 100 SEK to CHF

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.