diff options
-rw-r--r-- | .config/conkyrc | 6 | ||||
-rwxr-xr-x | .local/bin/conky_cover.sh | 21 |
2 files changed, 14 insertions, 13 deletions
diff --git a/.config/conkyrc b/.config/conkyrc index 53c2b7b..c1e485d 100644 --- a/.config/conkyrc +++ b/.config/conkyrc @@ -49,10 +49,10 @@ conky.text = [[ ${color grey}${alignc}${time %A %e %B %Y : %Hh%M} ${hr}${if_mpd_playing} ${color grey}${alignc}MPD -${font1}${color white}${goto 140}$mpd_artist -${goto 140}$mpd_album +${font1}${color white}${goto 140}${mpd_artist} +${goto 140}${mpd_title} ${goto 140}${mpd_elapsed}/${mpd_length} ${mpd_bar} -${execi 5 ~/.local/bin/conky_cover.sh >/dev/null 2>&1}${image /tmp/conkyCover.png -p 10,30 -n} +${execi 5 ~/.local/bin/conky_cover.sh >/dev/null 2>&1}${image /tmp/conkyCover.png -p 20,40 -n} ${hr}${endif}${if_up re0} ${font2}${color white}${alignc}${execi 1800 curl wttr.in/Lyon?T0 --silent --max-time 3}${font} ${hr}${endif} diff --git a/.local/bin/conky_cover.sh b/.local/bin/conky_cover.sh index 43bc65c..a0f3517 100755 --- a/.local/bin/conky_cover.sh +++ b/.local/bin/conky_cover.sh @@ -1,4 +1,4 @@ -#!/usr/local/bin/bash +#!/bin/sh # # cover.sh - Download cover from Last.fm and overlay with image # @@ -49,16 +49,17 @@ if [ ! -f "$COVER" ]; then fi # Copy cache for processing echo "Copying $COVER." >> $LOG -cp "$COVER" /tmp/cover.jpg +# cp "$COVER" /tmp/cover.jpg # Downscale to fit overlay -convert /tmp/cover.jpg -resize 366 /tmp/cover.png >> $LOG -# Enlarge canvas to fit overlay -convert /tmp/cover.png -background none -extent 500x455-84-44 /tmp/cover.png >> $LOG -# Overlay overlay over cover -convert /tmp/cover.png $HOME/.config/conky-mpd/case.png -composite /tmp/cover.png >> $LOG -# Resize for immediate use -convert /tmp/cover.png -resize 120 /tmp/conkyCover.png >> $LOG -# Set current artist +# convert /tmp/cover.jpg -resize 366 /tmp/cover.png >> $LOG +## Enlarge canvas to fit overlay +#convert /tmp/cover.png -background none -extent 500x455-84-44 /tmp/cover.png >> $LOG +## Overlay overlay over cover +#convert /tmp/cover.png $HOME/.config/conky-mpd/case.png -composite /tmp/cover.png >> $LOG +## Resize for immediate use +# convert /tmp/cover.png -resize 120 /tmp/conkyCover.png >> $LOG +convert "$COVER" -resize 100 /tmp/conkyCover.png >> $LOG +## Set current artist echo "$ARTIST+$ALBUM" > $TMP #rm /tmp/cover.jpg /tmp/cover.png |