How to use systemd to run a script regularly

I have a script that changes my background image based on what hour of the day it is. I would like to automate this so that it runs at the top of the hour, and when my machine first boots up. How do I go about getting this to work under systemd??

Hi DoctorKraz,

I don't know about scripting but this looks promising:

Hope it helps. :smiley:

The Arch wiki has a good overview on using systemd timers as a cron replacement: https://wiki.archlinux.org/index.php/Systemd/Timers#As_a_cron_replacement

It’s a little dense, and I’ve not tried it! :wink:

ok - i’ve tried both setting up a systemd timer/service and a cron job - and neither work. The script I want to run works. If I run it via command line, my background changes based on what hour of the day it is.

Any ideas???