_ _
|_ _ |_ _. ._ _ _ |_) _. _|_ _
|_ >< (_ | | (_| | | (_| (/_ | \ (_| |_ (/_
_|
A simple command-line tool to query exchange rate.
brew tap timothyye/tap
brew install timothyye/tap/exchangerate
go get github.com/TimothyYe/exchangerate/cmd/er
Download it from releases and extact it to /usr/bin or your PATH directory.
- Visit https://free.currencyconverterapi.com/free-api-key and get your free API key.
- Save your API key into
~/.er
file.
Your .er
file may looks like:
→ cat ~/.er
15d684b456848e2da877
% er -h
Exchange Rate V1.2
https://github.com/TimothyYe/exchangerate
NAME:
Exchange Rate - A simple command-line tool to query exchange rate
USAGE:
er [from currency] [amount] [to currency]
VERSION:
1.2
EXAMPLES:
er USD Query USD and show exchange rate for common used currencies.
er USD 40.98 Query USD with amount 40.98, and show the equal amount of other currencies.
er USD 12 CNY,JPY Query USD with amount 12 and show the equal amount of specified currencies.
GLOBAL OPTIONS:
--help, -h show help
--version, -v print the version