Skip to main content
Help us improve Python packaging – donate today!

A CLI app to see currency exchange rates.

Project Description

# **`exch`**

![travis CI stability badge](https://travis-ci.org/anshulc95/exch.svg?branch=master)
![python version supported badge](https://img.shields.io/pypi/pyversions/exch.svg)
![code coverage percentage of the current build badge](https://codecov.io/gh/anshulc95/exch/branch/master/graph/badge.svg)
[![PyPI version of the app badge](https://img.shields.io/pypi/v/exch.svg)](https://pypi.python.org/pypi/exch)

An application to see the currency exchange rates right from your command-line.

### Features:
* offline support
* default curreny
* list the available currencies

## Installation
```
$ pip install exch
```

## basic usage

```
$ exch -a 99 -b USD -t INR
99.0 USD = 6372.61 INR

$ exch --amount 199 --base EUR --target JPY
199.0 EUR = 25613.29 JPY
```


## Commands
|Short|Long|Description|Example|
|---|---|---|---|
|`-t`|`--target`|Currency you're converting to.|`exch -t INR`|
|`-b`|`--base`|Currency you're converting from.|`exch -b EUR`|
|`-a`|`--amount`|Amount of money to convert|`exch -a 99`|
|`-st`|`--set_target`|Set the new tagert currency|`exch -t CAD -st`|
|`-sb`|`--set_base`|Set the new tagert currency|`exch -b USD -sb`|
||`--help`|Show help message.|`exch --help`|
|`currencies`||List the Currencies that are available.|`exch currencies`|
|`sync`||Get the latest exchange rates for local use|`exch sync`|

## Advance usage

### Default amount is 1

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

### Default currencies

When no base or target given, the program assumes the default currencies.
```
$ exch
1.0 USD = 64.02 INR
```

Set the currency in use as default with `-sb` for base and `-st` for target.
```
$ exch -a 99 -b EUR -t NZD -sb -st
99.0 EUR = 168.00 NZD

$ exch
1.0 EUR = 1.70 NZD
```

## Built with

Programming language
* [Python3](https://www.python.org/)

Libraries used:
* [Click](http://click.pocoo.org/6/) - for making the command-line interface
* [Requests](http://docs.python-requests.org/en/master/) - for API calls

## Contribution

For contribution, please refer [CONTRIBUTING.md](CONTRIBUTING.md)

## Changlog

For changelog, please refer [CHANGELOG.md](CHANGELOG.md)

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE)
file for details


Release history Release notifications

This version
History Node

1.0

History Node

0.2

History Node

0.1.3b0

History Node

0.1

History Node

0.1rc1

Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
exch-1.0-py3-none-any.whl (7.8 kB) Copy SHA256 hash SHA256 Wheel py3 Dec 21, 2017
exch-1.0.tar.gz (5.7 kB) Copy SHA256 hash SHA256 Source None Dec 21, 2017

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page