diff options
author | ache <ache@ache.one> | 2019-03-26 08:54:55 +0100 |
---|---|---|
committer | ache <ache@ache.one> | 2019-03-26 08:54:55 +0100 |
commit | d43b829fa5f0564f33ac5cb5eb2fe43189c8717a (patch) | |
tree | 40be13d8e8f7c5f70a2354f49bed025a2dad5e17 | |
parent | Wayland compatible (diff) |
Save a Wallpaper
-rwxr-xr-x | autoWall.sh | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/autoWall.sh b/autoWall.sh index b3df352..7e17b82 100755 --- a/autoWall.sh +++ b/autoWall.sh @@ -8,6 +8,14 @@ if [ -n "$WAYLAND_DISPLAY" ] ; then cmd='swaymsg output "*" background %s fill' fi +if [ -e ~/.savedWall ] ; then + wall=$(cat ~/.savedWall) + cmd=$(printf "${cmd}" ${wall}) + echo ${cmd} + eval ${cmd} + exit +fi + for action in $@ do if [ ${action:0:1} = "+" ] @@ -27,6 +35,16 @@ do done echo fi + if [ ${action} = "save" ] + then + cp ~/.actWall ~/.savedWall + exit + fi + if [ ${action} = "unsave" ] + then + rm ~/.savedWall + exit + fi if [ ${action:0:1} = "-" ] then if [ -d ${wallDir}/${action:1} ] |