From 6bbf4c5f669ec1adbec4c3c4e88d0c6a705ae362 Mon Sep 17 00:00:00 2001 From: Manuel Palenzuela Date: Fri, 28 Jun 2019 18:30:54 +0200 Subject: added config file --- config | 6 ++++++ smart-wallpaper | 7 +------ 2 files changed, 7 insertions(+), 6 deletions(-) create mode 100644 config diff --git a/config b/config new file mode 100644 index 0000000..08d5f9f --- /dev/null +++ b/config @@ -0,0 +1,6 @@ +# Smart-Wallpaper CONFIG +# Variables for your wallpaper collection +# It can be a folder (e.g /home/user/wallpapers/*) or a file (/home/user/wallpapers/wallpaper.jpg) + +daytimewallpaper=~/Images/wave.jpg +nightimewallpaper=~/Images/city.jpg diff --git a/smart-wallpaper b/smart-wallpaper index 3035fac..3d300ec 100755 --- a/smart-wallpaper +++ b/smart-wallpaper @@ -1,7 +1,6 @@ #!/bin/bash -daytimewallpaper=~/Images/wave.jpg -nightimewallpaper=~/Images/city.jpg +source ~/.config/smart-wallpaper/config while true do @@ -10,19 +9,15 @@ do string=$(redshift -l $(cat /usr/share/geolocate/.location) -p) if [[ $string == *"Daytime"* ]]; then feh --randomize --bg-fill $daytimewallpaper - echo "geolocate found. DAYTIME" else feh --randomize --bg-fill $nightimewallpaper - echo "geolocate found. NIGHTTIME" fi else string=$(redshift -p) if [[ $string == *"Daytime"* ]]; then feh --randomize --bg-fill $daytimewallpaper - echo "geolocate NOT found. DAYTIME" else feh --randomize --bg-fill $nightimewallpaper - echo "geolocate NOT found. NIGHTTIME" fi fi -- cgit 1.4.1