This repository has been archived on 2021-03-24. You can view files and clone it, but cannot push or open issues or pull requests.
2020-05-27 02:31:42 +00:00
|
|
|
#!/bin/sh
|
2020-04-01 15:47:43 +00:00
|
|
|
|
|
|
|
bgloc="/tmp/bg"
|
2020-04-14 04:07:37 +00:00
|
|
|
dir="$HOME/img/wallpaper"
|
2020-04-01 15:47:43 +00:00
|
|
|
|
2020-04-14 04:07:37 +00:00
|
|
|
[ -f "$dir" ] && ln -sf "$(readlink -f "$dir")" "$bgloc"
|
|
|
|
[ -d "$dir" ] && ln -sf "$(find "$(readlink -f "$dir")" -iregex '.*.\(jpg\|jpeg\|png\|gif\)' -type f | shuf -n 1)" "$bgloc"
|
2020-04-01 15:47:43 +00:00
|
|
|
|
2020-04-14 04:07:37 +00:00
|
|
|
hsetroot -fill "$bgloc" >/dev/null 2>&1
|