skip to navigation
skip to content

exch 0.2

A CLI app to see currency exchange rates.

A command-line application built using python to see foreign exchange rates and currency conversion.

It parses exchange rates from the following service(s):

fixer.io

Installation:

$ pip install exch

Usage examples:

$ exch -a 99 -b USD -t INR
99.0 USD = 6343.92 INR
$ exch --amount 199 --base EUR --target JPY
199.0 EUR = 25613.29 JPY

Default amount for currency exchange is 1.

$ exch -b USD -t PHP
1.0 USD = 51.23 PHP

Change default curreny

$ exch
1.0 USD = 64.02 INR

Set the currency in use as default with -sb for base and -st for target.

$ exch -b EUR -t NZD -sb
1.0 EUR = 1.66 NZD

You can see the new set default base in action here.

$ exch
1.0 EUR = 76.63 INR

Similarly, setting new default target.

$ exch -b EUR -t CAD -st
1.0 EUR = 1.46 CAD
$ exch
1.0 EUR = 1.46 CAD

Setting both, new base and new target, as defaults.

$ exch -b PHP -t JPY -sb -st
1.0 PHP = 2.14 JPY
$ exch
1.0 PHP = 2.14 JPY

List of commands

Short Long Description Example
-t --target Currency you’re converting to. exch -t INR
-b --base Currency you’re converting from. exch -b USD
-a --amount The amount of base currency to convert. exch -a 99
-st --set_target Set new default target currency. exch -t PHP -st
-sb --set_base Set new default base currency. exch -b EUR -sb
-h --help Displays the help text. exch -h

Built With

  • Click - a Python package for creating beautiful command line interfaces.
  • requests - HTTP library for Python

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Contribution

For contribution, please refer CONTRIBUTING.md

 
File Type Py Version Uploaded on Size
exch-0.2-py3-none-any.whl (md5) Python Wheel py3 2017-09-18 6KB
exch-0.2.tar.gz (md5) Source 2017-09-18 4KB