customizable converter tool to convert <source> to <target>
Project description
converterpy
converterpy is designed as a customizable conversion tool to convert one thing to another.
Usage
usage: convert <value> <source> to <target> [optional arguments]
optional arguments:
-h, --help show help message
-v verbose mode
Examples
$ convert 3600 seconds to minutes -> '60'
$ convert 3600 sec to min -> '60'
$ convert 2500 g to kg -> '2.5'
$ convert 1610744400 ts to date -> '2021-01-16 00:00:00'
$ convert 100 centimeter to meter -> '1'
Features
There are some built-in converters to use;
- SITimeConverter (converts the following units: seconds, minutes, hours)
- SILengthConverter (converts the following units: millimeter, centimeter, meter, kilometer)
- SIMassConverter (converts the following units: milligram, gram, kilogram)
- TimestampDateConverter (converts unix timestamp to date, date to timestamp format)
Installation
converterpy
requires Python 3.5+ to run.
Install with pip
$ pip install converterpy
Custom Converters
Please follow the instructions in custom converter documentation.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
converterpy-0.0.1.dev3.tar.gz
(9.0 kB
view hashes)
Built Distribution
Close
Hashes for converterpy-0.0.1.dev3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0105dc69efad5a10dc5c229003140d1b2f2f7ba8f2447a2c53f4641bbcfad8c1 |
|
MD5 | 638cef8e71577c8a4c44ac92b586828a |
|
BLAKE2b-256 | a7f50a4bf583fe4bf6655b8dd63232fa24b5ee48edb1a6a3467b6987b964c521 |