feat(hyprlock): update
This commit is contained in:
15
hypr/scripts/cover.sh
Executable file
15
hypr/scripts/cover.sh
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
CACHE="$HOME/.cache/nowplaying-cover.jpg"
|
||||
|
||||
url=$(playerctl metadata mpris:artUrl 2>/dev/null)
|
||||
|
||||
# Kein Player aktiv
|
||||
[ -z "$url" ] && exit 0
|
||||
|
||||
# file:// prefix entfernen (Spotify lokal)
|
||||
if [[ "$url" == file://* ]]; then
|
||||
cp "${url#file://}" "$CACHE"
|
||||
else
|
||||
curl -sL "$url" -o "$CACHE"
|
||||
fi
|
||||
Reference in New Issue
Block a user