On previous occasions we have talked about how to change wallpaper randomlyIn this case we will do it without having to download the images ourselves, but our script will automatically download wallpaper from wallhaven and it will change it from time to time, as we configure it.
To achieve all this we must carry out a series of steps, which we will describe below:
Install Python-pip
We execute the following command from our terminal:
sudo apt install python-pip
Install required Dependencies
We execute the following commands from our terminal:
pip install BeautifulSoup4
pip install --upgrade pip
Installing the Necessary Scripts
We clone the repository with the scripts that will allow us to download random wallpaper and choose it as our wallpaper. To do this we execute the following commands:
git clone https://github.com/kirillsulim/ubuntu-wallpaper-switcher.git
cd ubuntu-wallpaper-switcher/
We execute the .sh in charge of starting the process in python that is responsible for carrying out the entire process:
./set-wallpaper.sh
Give execution permissions and schedule the time with which the wallpaper will change
We go to the desktop where the script was downloaded
cd ubuntu-wallpaper-switcher/
We give execution permissions to the .sh
chmod a+x set-wallpaper.sh
Then we schedule a crontab to run as desired, for example:
crontab -e
And we parameterize it in my case so that it changes every 45 minutes:
*/45 * * * * /home/lagarto/ubuntuswitcher/set-wallpaper.sh 2>&1 >> /var/log/tare$
You can learn to make the configuration you want for your crontab from this excellent article Cron & crontab, explained
The images of each of the wallpapers are housed in the script directory.
I hope you like this method and do not hesitate to leave us your comments.
Sakludos,
You can use this application that does the same. Variety is an open-source wallpaper changer for Linux
Please «sakludos» and «Puedem» “is an” put “is a”, correct the text thanks.
Variety didn't take it into account but now it does, thanks for the tip.
Hi I think it would look better if you put 2 bars in cinnamon then remove the bottom one and put the dock d plank. you would have plenty of space