nix: manage waybar with home-manager
This commit is contained in:
parent
c4438e063b
commit
c8bb94806d
@ -1,17 +0,0 @@
|
||||
# ~/.config/systemd/user/waybar.service or /etc/systemd/user/waybar.service
|
||||
[Unit]
|
||||
Description=Highly customizable Wayland bar for Sway and Wlroots based compositors.
|
||||
Documentation=https://github.com/Alexays/Waybar/wiki/
|
||||
#PartOf=graphical-session.target
|
||||
PartOf=sway-session.target
|
||||
After=sway-session.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/waybar
|
||||
# Upstreamed in https://github.com/Alexays/Waybar/pull/1036
|
||||
ExecReload=kill -SIGUSR2 $MAINPID
|
||||
Restart=on-failure
|
||||
RestartSec=5s
|
||||
|
||||
[Install]
|
||||
WantedBy=sway-session.target
|
@ -1,2 +0,0 @@
|
||||
[Service]
|
||||
Environment=PATH=%h/bin:/usr/local/bin:/usr/bin
|
19
home-leo.nix
19
home-leo.nix
@ -83,6 +83,7 @@ in {
|
||||
bemenu
|
||||
swayr
|
||||
kanshi
|
||||
waybar
|
||||
];
|
||||
|
||||
imports = [
|
||||
@ -117,6 +118,24 @@ in {
|
||||
Install = {WantedBy = [config.services.kanshi.systemdTarget];};
|
||||
};
|
||||
|
||||
waybar = {
|
||||
Unit = {
|
||||
Description = "Highly customizable Wayland bar for Sway and Wlroots based compositors.";
|
||||
Documentation = "https://github.com/Alexays/Waybar/wiki/";
|
||||
PartOf = swayTgt;
|
||||
After = swayTgt;
|
||||
};
|
||||
|
||||
Service = {
|
||||
ExecStart = "${pkgs.waybar}/bin/waybar";
|
||||
ExecReload = "kill -SIGUSR2 $MAINPID";
|
||||
Restart = "on-failure";
|
||||
RestartSec = "3s";
|
||||
};
|
||||
|
||||
Install = {WantedBy = [swayTgt];};
|
||||
};
|
||||
|
||||
autotiling = {
|
||||
Unit = {
|
||||
Description = "Script for sway and i3 to automatically switch the horizontal / vertical window split orientation";
|
||||
|
Loading…
Reference in New Issue
Block a user