random bash scripts
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
246 B

  1. #!/usr/bin/env sh
  2. set -eo pipefail
  3. interval=120
  4. if [ -z "$1" ]; then
  5. interval="$1"
  6. fi
  7. weather() {
  8. clear
  9. curl -H "Accept-Language: ${LANG%_*}" --silent wttr.in/"$1" 2>&1
  10. sleep "$interval"
  11. }
  12. while true; do
  13. weather dublin
  14. weather moon
  15. done