Share hypr_refresh; capture the work laptop's own units
Both laptops run hypr_refresh and their unit files had diverged. The work laptop's is the refined one — Type=oneshot, which is correct for a script that exits, a 15s interval with AccuracySec, and a comment explaining the wallpaper-daemon guard. system76 had Type=simple with Restart=on-failure, which respawns a oneshot script continuously. Shared version wins. Three more units existed only on the work laptop and were untracked: backlight-probe, kanshi and mopidy.
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
[Unit]
|
||||
Description=Refresh Hyprland wallpaper and colorscheme
|
||||
After=graphical-session.target
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=%h/.dotfiles/common/bin/hypr_refresh
|
||||
@@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=Refresh Hyprland wallpaper/colorscheme every 15 seconds
|
||||
|
||||
[Timer]
|
||||
# First run shortly after login (guard in the script no-ops if the wallpaper
|
||||
# daemon isn't up yet), then every 15s thereafter.
|
||||
OnBootSec=30sec
|
||||
OnUnitActiveSec=15sec
|
||||
AccuracySec=1s
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
||||
@@ -0,0 +1,9 @@
|
||||
[Unit]
|
||||
Description=Sample backlight state to diagnose failed restores
|
||||
|
||||
[Service]
|
||||
ExecStart=%h/.dotfiles/hosts/sctfw004/bin/backlight-probe
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
||||
@@ -0,0 +1,21 @@
|
||||
[Unit]
|
||||
Description=kanshi dynamic output configuration
|
||||
PartOf=graphical-session.target
|
||||
StartLimitIntervalSec=60
|
||||
StartLimitBurst=5
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/bin/kanshi
|
||||
Restart=always
|
||||
RestartSec=1
|
||||
|
||||
# kanshi 1.5.1 can wedge into a tight profile-list loop that forks a shell per
|
||||
# iteration. These bound the blast radius rather than prevent it.
|
||||
CPUQuota=20%
|
||||
LogRateLimitIntervalSec=10s
|
||||
LogRateLimitBurst=200
|
||||
TasksMax=64
|
||||
|
||||
[Install]
|
||||
WantedBy=graphical-session.target
|
||||
@@ -0,0 +1,10 @@
|
||||
[Unit]
|
||||
Description=Mopidy music server
|
||||
After=network.target sound.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/mopidy --config /etc/mopidy/mopidy.conf
|
||||
Restart=on-failure
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
||||
@@ -1,11 +0,0 @@
|
||||
[Unit]
|
||||
Description=Refresh Hyprland Wallpaper and Colors
|
||||
After=graphical-session.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=%h/.dotfiles/common/bin/hypr_refresh
|
||||
Restart=on-failure
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
||||
@@ -1,9 +0,0 @@
|
||||
[Unit]
|
||||
Description=Run hypr_refresh every minute after boot
|
||||
|
||||
[Timer]
|
||||
OnBootSec=1min
|
||||
OnUnitActiveSec=1min
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
||||
@@ -10,6 +10,11 @@
|
||||
force: true
|
||||
|
||||
- link:
|
||||
~/.config/systemd/user/hypr_refresh.service: common/systemd/hypr_refresh.service
|
||||
~/.config/systemd/user/hypr_refresh.timer: common/systemd/hypr_refresh.timer
|
||||
~/.config/systemd/user/backlight-probe.service: hosts/sctfw004/systemd/backlight-probe.service
|
||||
~/.config/systemd/user/kanshi.service: hosts/sctfw004/systemd/kanshi.service
|
||||
~/.config/systemd/user/mopidy.service: hosts/sctfw004/systemd/mopidy.service
|
||||
~/.config/beets: common/beets
|
||||
~/.config/bottom: common/bottom
|
||||
~/.config/fastfetch: common/fastfetch
|
||||
@@ -60,3 +65,7 @@
|
||||
~/.config/waybar/style.css: common/waybar/style.css
|
||||
~/.config/waybar/sshuttle-status.sh: common/waybar/sshuttle-status.sh
|
||||
~/.config/waybar/local.css: hosts/sctfw004/waybar/local.css
|
||||
|
||||
- shell:
|
||||
- command: systemctl --user daemon-reload
|
||||
description: Reloading user units
|
||||
|
||||
@@ -51,8 +51,8 @@
|
||||
~/.config/waybar/style.css: common/waybar/style.css
|
||||
~/.config/waybar/sshuttle-status.sh: common/waybar/sshuttle-status.sh
|
||||
~/.config/waybar/local.css: hosts/system76/waybar/local.css
|
||||
~/.config/systemd/user/hypr_refresh.service: hosts/system76/systemd/hypr_refresh.service
|
||||
~/.config/systemd/user/hypr_refresh.timer: hosts/system76/systemd/hypr_refresh.timer
|
||||
~/.config/systemd/user/hypr_refresh.service: common/systemd/hypr_refresh.service
|
||||
~/.config/systemd/user/hypr_refresh.timer: common/systemd/hypr_refresh.timer
|
||||
|
||||
- shell:
|
||||
- command: systemctl --user daemon-reload
|
||||
|
||||
Reference in New Issue
Block a user