*dance*
This commit is contained in:
parent
be3df6718f
commit
57e53e8eb7
1 changed files with 33 additions and 29 deletions
|
@ -1,11 +1,7 @@
|
||||||
from util import http, hook
|
from util import http, hook
|
||||||
|
|
||||||
|
## CONSTANTS
|
||||||
|
|
||||||
@hook.command("butt", autohelp=False)
|
|
||||||
@hook.command("btc", autohelp=False)
|
|
||||||
@hook.command(autohelp=False)
|
|
||||||
def bitcoin(inp):
|
|
||||||
"bitcoin <exchange> -- Gets current exchange rate for bitcoins from several exchanges, default is Blockchain. Supports MtGox, Bitpay, Coinbase and BitStamp."
|
|
||||||
exchanges = {
|
exchanges = {
|
||||||
"blockchain": {
|
"blockchain": {
|
||||||
"api_url": "https://blockchain.info/ticker",
|
"api_url": "https://blockchain.info/ticker",
|
||||||
|
@ -33,6 +29,13 @@ def bitcoin(inp):
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
## HOOK FUNCTIONS
|
||||||
|
|
||||||
|
@hook.command("btc", autohelp=False)
|
||||||
|
@hook.command(autohelp=False)
|
||||||
|
def bitcoin(inp):
|
||||||
|
"""bitcoin <exchange> -- Gets current exchange rate for bitcoins from several exchanges, default is Blockchain. Supports MtGox, Bitpay, Coinbase and BitStamp."""
|
||||||
inp = inp.lower()
|
inp = inp.lower()
|
||||||
|
|
||||||
if inp:
|
if inp:
|
||||||
|
@ -48,6 +51,7 @@ def bitcoin(inp):
|
||||||
return func(data)
|
return func(data)
|
||||||
|
|
||||||
|
|
||||||
|
@hook.command("ltc", autohelp=False)
|
||||||
@hook.command(autohelp=False)
|
@hook.command(autohelp=False)
|
||||||
def litecoin(inp, message=None):
|
def litecoin(inp, message=None):
|
||||||
"""litecoin -- gets current exchange rate for litecoins from BTC-E"""
|
"""litecoin -- gets current exchange rate for litecoins from BTC-E"""
|
||||||
|
|
Reference in a new issue