Add today and update function
This commit is contained in:
parent
97669b90af
commit
e671679932
|
@ -128,6 +128,15 @@ anniversary() {
|
||||||
jq "$jqNewUD" <<<$jsonData
|
jq "$jqNewUD" <<<$jsonData
|
||||||
}
|
}
|
||||||
|
|
||||||
|
today() {
|
||||||
|
todayDate=$(date +'%d-%m-%y')
|
||||||
|
jq '.[] | select(.date=="'$todayDate'")' <<<$jsonData
|
||||||
|
}
|
||||||
|
|
||||||
|
update() {
|
||||||
|
curl -s https://g1-stats.axiom-team.fr/data/daily.json > $jsonFile && echo "Data have been updated" || echo "Error: Can't update data"
|
||||||
|
}
|
||||||
|
|
||||||
print() {
|
print() {
|
||||||
jq . <<<"$jsonData"
|
jq . <<<"$jsonData"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue