add btc price print script
Prithu Goswami prithugoswami524@gmail.com
Tue, 08 Dec 2020 09:41:26 +0530
2 files changed,
11 insertions(+),
0 deletions(-)
A
bin/scripts/print_btc_price
@@ -0,0 +1,7 @@
+#!/usr/bin/sh + +url="https://api.coindcx.com/exchange/ticker" + +btc_price=$(curl -sL $url | jq -r '"\(.[0].last_price) \(.[0].change_24_hour)"') + +echo " $btc_price"
M
i3blocks/config
→
i3blocks/config
@@ -19,6 +19,10 @@ # markup=pango
# command=~/.config/i3blocks/pacupdate # interval=once # signal=8 +[btcprice] +command=print_btc_price +interval=120 +markup=pango [reminder] command=~/.config/i3blocks/note