From dc7172b5af4c3683a17d81af6a8097b17b2da38c Mon Sep 17 00:00:00 2001 From: Fedor V Date: Sun, 15 Jan 2023 22:25:52 +0300 Subject: [PATCH] Create wetter.sh --- misc/wetter.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 misc/wetter.sh diff --git a/misc/wetter.sh b/misc/wetter.sh new file mode 100644 index 0000000..fa5ca2c --- /dev/null +++ b/misc/wetter.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +# curl https://www.ard-text.de/mobil/171 | grep -zPo "

(.|\n)*

" > wetter-`date +%F-%H-%M`.txt +# cat page.html | grep -zPo "
(.|\n)*?
" | xmllint --xpath '//p/text()' - | xargs echo | sed 's/\. /\.\n/g' + +curl -sS https://www.ard-text.de/mobil/171 | \ + grep -zPo "
(.|\n)*?
" | \ + xmllint --xpath '//text()' - | \ + xargs echo | \ + sed 's/\. /\.\n/g' | \ + tee wetter-`date +%F-%H-%M`.txt