config/neofetch: raise weather timeout and add ip
This commit is contained in:
parent
a5250eca33
commit
ea580a3385
|
@ -9,7 +9,8 @@ print_info() {
|
||||||
info "Host" model
|
info "Host" model
|
||||||
info "Uptime" uptime
|
info "Uptime" uptime
|
||||||
info "Memory" memory
|
info "Memory" memory
|
||||||
prin "Weather" "$(timeout .4s curl --max-time 0.2 'wttr.in/?0?q?T' | awk '/°(C|F)/ {printf $(NF-1) $(NF) " ("a")"} /,/ {a=$0}' || echo Timeout)"
|
prin "Weather" "$(timeout 1s curl --max-time 0.3 'wttr.in/?0?q?T' | awk '/°(C|F)/ {printf $(NF-1) $(NF) " ("a")"} /,/ {a=$0}' || echo Timeout)"
|
||||||
|
prin "IP" "$(curl ifconfig.me && printf " / " && curl icanhazip.com)"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -37,7 +37,9 @@ print_info() {
|
||||||
# info "Install Date" install_date
|
# info "Install Date" install_date
|
||||||
# info "Locale" locale # This only works on glibc systems.
|
# info "Locale" locale # This only works on glibc systems.
|
||||||
|
|
||||||
prin "Weather" "$(curl wttr.in/?0?q?T -m 0.1 | awk '/°(C|F)/ {printf $(NF-1) $(NF) " ("a")"} /,/ {a=$0}' || echo Timeout)"
|
prin "Weather" "$(curl wttr.in/?0?q?T -m 0.3 | awk '/°(C|F)/ {printf $(NF-1) $(NF) " ("a")"} /,/ {a=$0}' || echo Timeout)"
|
||||||
|
prin "IP" "$(curl ifconfig.me)"
|
||||||
|
prin "IPv6" "$(curl icanhazip.com)"
|
||||||
|
|
||||||
info line_break
|
info line_break
|
||||||
info cols
|
info cols
|
||||||
|
|
Loading…
Reference in New Issue