This project is composed of three files :
- scrapping.sh
- stats.sh
- test.sh
This script takes the takes the file in which the values scrapped by the first script are saved and computes the minimal value, the maximum value and the mean.
The last file is a test that both recovers the data and calculates them over an interval defined when it is launched. It doesn't send any message to telegram, it just echo them.
For both scrapping.sh and stats.sh, we use crontab -e to launch the scripts every 5 minutes for the first one and every day at 18 o'clock for the second one.
And this is the result on the telegram bot with scrapping.sh being executed every minutes and stats.sh every ten minutes :