So, I started breaking up my system init and creating some service files for things I want to be loaded after I login. It's the usual stuff like polybar, dunst and the rest of the things. Things do work, but I have some issues with my pywal setup. I've separated the dependencies into a separate .target called
theme.target
[Unit]
Description = Theme dependencies
BindsTo = xsession.target
Wants = pywal.service
Wants = i3.service
Wants = polybar.service
Wants = dunst.service
What I want to achieve is to have i3 (and the rest of the list for that matter) to load only after pywal.service is fully running and has finished execution of the start up script.
In .bin/pywal I do have a sleep of 10s
pywal.service
[Unit]
Description = Run pywal service responsible for color schemes
PartOf = theme.target
[Service]
ExecStart = %h/.bin/pywal
[Install]
WantedBy = theme.target
i3.service
[Unit]
Description = A tiling window manager
PartOf = theme.target
After = pywal.service
Requires = pywal.service
[Service]
ExecStart = /usr/bin/i3-msg restart
[Install]
WantedBy = theme.target
I might be confused here with what "successfully running" actually means, but i3 service I noticed restarts immediately once I run
systemctl --user restart theme.target
I'm then just watching status on all 3 services/targets and see that the i3 has restarted at the same time as pywal.service.
So basically what am I missing here and why does i3 not restart 10 seconds after pywal?
Edit: fixed a sentence to make more sense in this context based on the comment