mirror of
https://github.com/alexanderepstein/Bash-Snippets
synced 2018-11-08 02:59:35 +01:00
Update Readme, add BCH (#120)
This commit is contained in:
parent
4cc8703448
commit
7c8d5f94b2
2 changed files with 12 additions and 5 deletions
12
README.md
12
README.md
|
@ -90,9 +90,15 @@ Converts Cryptocurrency based on realtime exchange rates
|
|||
|
||||
</div>
|
||||
|
||||
If you want to bypass to guided input you can pass in 3 arguments and it will run from there
|
||||
ex.```currency [baseCurrency] [exchangeToCurrency] [amountBeingExchanged]```
|
||||
so a valid use case would be ```currency BTC USD 12.35```
|
||||
Run `cryptocurrency` and you'll be guided through providing three arguments.
|
||||
1. Base currency, i.e. `BTC`
|
||||
2. Target currency, i.e. `USD`
|
||||
3. Amount, i.e. `12.35`
|
||||
|
||||
If you want to bypass the guided input you can pass in 3 arguments and it will run from there, i.e.
|
||||
```cryptocurrency [baseCurrency] [exchangeToCurrency] [amountBeingExchanged]```
|
||||
A valid use case would be:
|
||||
```cryptocurrency BTC USD 12.35```
|
||||
|
||||
Written by: [Jonas-Taha El Sesiy](https://github.com/elsesiy)
|
||||
</details>
|
||||
|
|
|
@ -40,7 +40,7 @@ checkValidCurrency()
|
|||
if [[ $1 != "BTC" && $1 != "ETH" \
|
||||
&& $1 != "XRP" && $1 != "LTC" && $1 != "XEM" \
|
||||
&& $1 != "ETC" && $1 != "DASH" && $1 != "MIOTA" \
|
||||
&& $1 != "XMR" && $1 != "STRAT" ]]; then
|
||||
&& $1 != "XMR" && $1 != "STRAT" && $1 != "BCH" ]]; then
|
||||
echo "1"
|
||||
else
|
||||
echo "0"
|
||||
|
@ -101,6 +101,7 @@ transformBase()
|
|||
"MIOTA") reqId="iota" ;;
|
||||
"XMR") reqId="monero" ;;
|
||||
"STRAT") reqId="stratis" ;;
|
||||
"BCH") reqId="bitcoin-cash" ;;
|
||||
esac
|
||||
}
|
||||
|
||||
|
@ -248,7 +249,7 @@ Supported Base Currencies:
|
|||
___________________________
|
||||
| BTC | ETH | XRP | LTC |
|
||||
| XEM | ETC | DASH | MIOTA |
|
||||
| XMR | STRAT |
|
||||
| XMR | STRAT | BCH |
|
||||
___________________________
|
||||
|
||||
Supported Target Currencies:
|
||||
|
|
Loading…
Reference in a new issue