aboutsummaryrefslogtreecommitdiff
path: root/wcli-query
diff options
context:
space:
mode:
authorKrow Savcik <krow@savcik.xyz>2024-01-07 15:18:29 +0200
committerKrow Savcik <krow@savcik.xyz>2024-01-07 15:18:29 +0200
commit5138d33e0c0adb0c4d13977af047e375eee934d8 (patch)
tree543825c957813dca637acacc8e5b7574c0979fb3 /wcli-query
initial commit
Diffstat (limited to 'wcli-query')
-rwxr-xr-xwcli-query9
1 files changed, 9 insertions, 0 deletions
diff --git a/wcli-query b/wcli-query
new file mode 100755
index 0000000..109723f
--- /dev/null
+++ b/wcli-query
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+dir="$HOME/.local/share/wcli"
+file="$dir/$(date +info_%F_%H-%M.json)"
+country=""
+
+mkdir -p "$dir" || exit 1
+curl "wttr.in/${country}?format=j1" -o "$file" || exit 1
+wcli-gen "$file"