This commit is contained in:
Shihaam Abdul Rahman 2023-11-12 21:54:23 +05:00
parent 41b0ef8a45
commit 68edfdea31
Signed by untrusted user: shihaam
GPG Key ID: 6DA2E87EBC227636

5
bot.sh
View File

@ -13,7 +13,6 @@ speedtest_fast=data/speedtest_fast_$date.json
weather_file=data/weather_$date.json weather_file=data/weather_$date.json
edited_image=data/edited_image_$date.png edited_image=data/edited_image_$date.png
################################################################################# #################################################################################
latency(){ latency(){
echo $(ping -c 1 $1) | \ echo $(ping -c 1 $1) | \
@ -94,11 +93,9 @@ echo Speedtests complete
################################################################################# #################################################################################
################################################################################# #################################################################################
valorant_ping=$(latency dynamodb.ap-southeast-1.amazonaws.com) valorant_ping=$(latency dynamodb.ap-southeast-1.amazonaws.com)
cfdns_ping=$(latency 1.1.1.1) cfdns_ping=$(latency 1.1.1.1)
googledns_ping=$(latency 8.8.8.8) googledns_ping=$(latency 8.8.8.8)
################################################################################# #################################################################################
################################################################################# #################################################################################
@ -122,7 +119,6 @@ echo Weather checked
################################################################################# #################################################################################
################################################################################# #################################################################################
total_wasted=$(echo $ookla_total+$libre_total+$fast_total | bc) total_wasted=$(echo $ookla_total+$libre_total+$fast_total | bc)
caption=" caption="
@ -170,6 +166,7 @@ curl -X POST https://api.telegram.org/bot$TG_BOT_TOKEN/sendMediaGroup \
-F photo1=@$camera_image \ -F photo1=@$camera_image \
-F photo2=@$satellite_image >> /dev/null -F photo2=@$satellite_image >> /dev/null
################################################################################# #################################################################################
echo Ok done, Sleeping for $DELAY echo Ok done, Sleeping for $DELAY
sleep $DELAY sleep $DELAY