forked from shihaam/starlink_status
more weather conditions added
This commit is contained in:
parent
ba4041feb2
commit
ab604a2016
34
bot.sh
34
bot.sh
@ -108,13 +108,33 @@ curl -s "https://api.open-meteo.com/v1/forecast?latitude=${LATITUDE}&longitude=$
|
|||||||
weather_condition=$(cat $weather_file | jq '.current_weather.weathercode')
|
weather_condition=$(cat $weather_file | jq '.current_weather.weathercode')
|
||||||
case $weather_condition in
|
case $weather_condition in
|
||||||
0) current_weather="☀️ Clear sky" ;;
|
0) current_weather="☀️ Clear sky" ;;
|
||||||
1|2|3) current_weather="☁️ Cloudy" ;;
|
1) current_weather="☀️ Mainly clear";;
|
||||||
45|48) current_weather="🌫️ Fog" ;;
|
2) current_weather="☁️ Partly cloudy" ;;
|
||||||
51|53|55|56|57) current_weather="🌧️ Drizzle" ;;
|
3) current_weather="☁️ Overcast" ;;
|
||||||
61|63|65|66|67) current_weather="🌦️ Rain" ;;
|
45) current_weather="🌫️ Fog" ;;
|
||||||
80|81|82) current_weather="🌧️ Rain showers" ;;
|
48) current_weather="🌫️ Depositing rime fog" ;;
|
||||||
85|86) current_weather="🌨️ Snow showers" ;;
|
51) current_weather="🌧️ Light drizzle" ;;
|
||||||
95|96|99) current_weather="⛈️ Thunderstorm" ;;
|
53) current_weather="🌧️ Moterate drizzle" ;;
|
||||||
|
55) current_weather="🌧️ Dense drizzle" ;;
|
||||||
|
56) current_weather="🌧️ Light freezing drizzle" ;;
|
||||||
|
57) current_weather="🌧️ Dense freezing drizzle" ;;
|
||||||
|
61) current_weather="🌦️ Slight rain" ;;
|
||||||
|
63) current_weather="🌦️ Moderate rain" ;;
|
||||||
|
65) current_weather="🌦️ Heavy rain" ;;
|
||||||
|
66) current_weather="🌦️ Light freezing rain" ;;
|
||||||
|
67) current_weather="🌦️ Heavy freezing rain" ;;
|
||||||
|
71) current_weather="🌨️ Slight snow fall" ;;
|
||||||
|
73) current_weather="🌨️ Moderate snow fall" ;;
|
||||||
|
75) current_weather="🌨️ Heavy snow fall" ;;
|
||||||
|
77) current_weather="🌨️ Snow grains" ;;
|
||||||
|
80) current_weather="🌧️ Slight rain showers" ;;
|
||||||
|
81) current_weather="🌧️ Moderate rain showers" ;;
|
||||||
|
82) current_weather="🌧️ Violent rain showers" ;;
|
||||||
|
85) current_weather="🌨️ Slight nnow showers" ;;
|
||||||
|
86) current_weather="🌨️ Heavy snow showers" ;;
|
||||||
|
95) current_weather="⛈️ Slight thunderstorm" ;;
|
||||||
|
96) current_weather="⛈️ Thunderstorm with slight hail" ;;
|
||||||
|
99) current_weather="⛈️ Thunderstorm with heavy hail" ;;
|
||||||
*) current_weather="🌐 Weather condition not recognized" ;;
|
*) current_weather="🌐 Weather condition not recognized" ;;
|
||||||
esac
|
esac
|
||||||
echo Weather checked
|
echo Weather checked
|
||||||
|
Loading…
x
Reference in New Issue
Block a user