Linux might not be the first operating system that comes to mind when you talk about customizations, but the opposite is true. While most Linux distributions seem plain and boring when you first start up, there are tons of customization options to make your desktop unique.
If you are a seasoned Linux user, you may have found that Linux can offer more personalization depending on the desktop environment and window manager you use. Let's take the first step towards a better desktop appearance and switch to dynamic wallpapers.
What is a dynamic background?
Static background images are background images that do not change automatically over a period of time. These are the background images built into your Linux distribution and desktop environment. However, you can go beyond the regular static wallpapers and take a leap towards dynamic wallpapers.
Dynamic background image is a simple bash script that allows you to set background images according to the current time using a cron job scheduler. Confused What That Means? In short, you can set different wallpapers for different times of the day. Imagine using a lighter version of the wallpaper during the day and a darker one at night. With dynamic background you can make your desktop look reactive.
Although there are over 25 different wallpaper sets in different resolutions, from HD to 5K, you can also create your own wallpaper set for a customized look. It also supports pywal, a tool that generates a color palette from the dominant colors in an image and then applies the colors system-wide and to all your favorite programs.
Can you use dynamic wallpaper?
Most Linux desktop environments and window managers support dynamic wallpapers. Here is an official list of all of the desktop environments and window managers that Dynamic Wallpaper will work with:
Super World Cup
Don't worry if your desktop environment or window manager isn't on this list. You can still try and use the test script to confirm if it works on your system.
Install dynamic wallpaper on Linux
Before you start the installation dwall (Dynamic Wallpaper) you need to install all the necessary dependencies for it to work properly. Depending on the Linux distribution you are using, run one of the two commands below to install the dependencies.
For Arch Linux and Arch-based distributions:
sudo pacman -Sy feh cronie python-pywal xorg-xrandr
If you're not running the Xfce desktop environment, you can remove it xorg-xrandr Package from the above command as you don't need it if you are using other desktop environments. You can also remove it pywal if you don't want to use it.
For Ubuntu and other Debian-based distributions:
sudo apt-get install x11-xserver-utils fail cron
You can also use the x11-xserver-utils Package if you are not running the Xfce desktop environment.
Now that you've installed all of the dependencies, it's time to get the latest dwall Tool. This is a simple process and you can start cloning the Git repository. This is how it works:
Git clone https://github.com/adi1090x/dynamic-wallpaper.git
CD dynamic wallpaper
If you want to test the bash script before proceeding with the installation, you can do that test.sh Script with the following command:
As you may have noticed, there are over 25 different wallpaper sets to choose from. For example, if you have the factory To set the background image to test the script, you can run this command:
./test.sh -s factory
You will find that your wallpaper has been automatically changed to your desired wallpaper set depending on the time of day.
After testing, you may want to install the script if you haven't encountered any problems. In the directory you will find a special a install.sh Script for this very purpose. To install dwallall you have to do is run this script.
And let's go. You have successfully installed dwall on your Linux computer. You can switch between different wallpaper sets and dwall automatically applies the corresponding background image from the set depending on the time.
But that's not all. Right now you're doing the dwall Script every few hours to update your background. To avoid this, you can set up a cron job and automate this process, which you will see in the next section.
Dynamic wallpaper automation with cron jobs
Finally, to automatically switch the background images, you need to set up a cron job. Cron is a Linux command that allows you to schedule commands or tasks to run repeatedly at a later time. In your case, you'll need a cron job to run dwall every hour. You can start by doing the cron service on your system using the commands given below.
For Arch-based distributions:
sudo systemctl activate cronie.service –now
To enable the cron service on Ubuntu and other Debian-based distributions:
sudo systemctl activate cron
Once this is done, you will need to find out the values of some environment variables before you can proceed with creating a cron job. Run this command on your terminal and write down the values:
echo "$ SHELL | $ PATH | $ DISPLAY | $ DESKTOP_SESSION | $ DBUS_SESSION_BUS_ADDRESS | $ XDG_RUNTIME_DIR"
The output on your terminal may differ from the one shown in the picture above. Don't worry about that as it differs on different devices. Now you can create a cron job with crontab.
A text editor opens in which you can add a new cron job. Paste the command given below into the editor, but make sure to replace the environment variables with your own values.
0 * * * * env PATH = DISPLAY = DESKTOP_SESSION = DBUS_SESSION_BUS_ADDRESS = ""/ usr / bin / dwall -s
Make sure to replace all of the values in it in the above command <> with your own environment variables and remove the <>. And that's it, you've successfully created a cron job to dynamically change your wallpaper.
To remove your previous cron job and use a different background set, you can run the following commands:
A text editor window is displayed again. This time you can choose a different wallpaper by clicking the Variable with a new value.
Enjoy a vibrant desktop with a dynamic background
Dynamic wallpapers are one of the best ways to start personalizing your Linux experience. You can even take it to the next level with a customizable desktop environment like KDE Plasma or a window manager like i3. It does, however, require a little tinkering on your part.
Do you fancy the macOS look and feel? Guess Linux can do that too. Here is a summary of how you can customize your GNOME, Xfce, KDE Plasma, Unity, or Cinnamon desktop environment to mimic the look and feel of macOS.
Make Linux look like macOS with these simple tweaks
If you like Linux but want it to look more like macOS, you're in luck! Here's how to make your Linux desktop look like macOS.
About the author
(15 articles published)
By Nitin Ranganath
Subscribe to our newsletter
Subscribe to our newsletter for tech tips, reviews, free e-books, and exclusive offers!
One more step …!
Please confirm your email address in the email we just sent you.