Set specific wallpaper instead of random one.

This commit is contained in:
Kolan Sh 2014-01-05 12:21:07 +04:00
parent fd27123164
commit 4ee66e7511
3 changed files with 10 additions and 3 deletions

View File

@ -8,4 +8,4 @@ os.execute ("pgrep firefox || (firefox || firefox-bin) &")
os.execute ("pgrep thunderbird || thunderbird &")
os.execute ("pgrep liferea || liferea &")
os.execute ("smbnetfs "..os.getenv("HOME").."/smb")
os.execute (os.getenv("HOME").."/.config/awesome/set_wall.sh "..os.getenv("HOME").."/wallpapers/")
os.execute (os.getenv("HOME").."/.config/awesome/set_wall.sh "..os.getenv("HOME").."/.config/awesome/wallpaper.slink")

View File

@ -1,3 +1,9 @@
#!/bin/sh
feh --bg-scale "$(find $1 | shuf -n1)"
if [ -d $1 ]; then
f="$(find $1 | shuf -n1)"
ln -sf "$f" ~/.config/awesome/wallpaper.slink
feh --bg-scale "$f"
else
feh --bg-scale $1
fi

View File

@ -1,2 +1,3 @@
-- theme.wallpaper_cmd = { "awsetbg -a "..os.getenv("HOME").."/.config/awesome/wallpaper.png" }
theme.wallpaper_cmd = { os.getenv("HOME").."/.config/awesome/set_wall.sh "..os.getenv("HOME").."/wallpapers/" }
-- theme.wallpaper_cmd = { os.getenv("HOME").."/.config/awesome/set_wall.sh "..os.getenv("HOME").."/wallpapers/" }
theme.wallpaper_cmd = { os.getenv("HOME").."/.config/awesome/set_wall.sh "..os.getenv("HOME").."/.config/awesome/wallpaper.slink" }