14 lines
635 B
Bash
14 lines
635 B
Bash
|
#!/bin/bash
|
||
|
date='date +%Y-%m-%d\ %T'
|
||
|
logfile=~/.wkgen.log
|
||
|
filelocation=/home/plex/Pictures/wallpaper/wk-progress.1.png
|
||
|
set -e
|
||
|
echo "[$(eval $date)]: starting webrequests..." | tee -a $logfile
|
||
|
curl -s -o $filelocation "https://wkgen.homeserver.box/?k=7b98a684-5c91-44ab-86b1-f7023609fe4e&d=1"
|
||
|
echo "[$(eval $date)]: setting wallpaper..." | tee -a $logfile
|
||
|
kwriteconfig5 \
|
||
|
--file "$HOME/.config/plasma-org.kde.plasma.desktop-appletsrc" \
|
||
|
--group 'Containments' --group '1' --group 'Wallpaper' --group 'org.kde.image' \
|
||
|
--group 'General' --key 'Image' $filelocation
|
||
|
echo "[$(eval $date)]: done" | tee -a $logfile
|