Skip to content

waybar.service: Use sway-session.target instead of graphical-session.target#5135

Closed
leigh123linux wants to merge 1 commit into
Alexays:masterfrom
leigh123linux:master
Closed

waybar.service: Use sway-session.target instead of graphical-session.target#5135
leigh123linux wants to merge 1 commit into
Alexays:masterfrom
leigh123linux:master

Conversation

@leigh123linux

Copy link
Copy Markdown

graphical-session.target is now activated by multiple desktop environments
including GNOME and Cinnamon. waybar only functions under wlroots-based
Wayland compositors so WantedBy=graphical-session.target causes it to be
started unconditionally in any graphical session.

Use WantedBy=sway-session.target to scope waybar to Sway sessions only.
Users of other wlroots compositors can enable it manually against their
own session target.

@leigh123linux

Copy link
Copy Markdown
Author

@alebastr

@RobertMueller2

Copy link
Copy Markdown
Contributor

should solve issue #3955

@Alexays

Alexays commented Jul 3, 2026

Copy link
Copy Markdown
Owner

Thanks! We can't take this as-is: switching WantedBy to sway-session.target makes the unit Sway-specific, but Waybar targets "Sway and Wlroots based compositors" — river/Hyprland/other wlroots setups rely on graphical-session.target, so this would break autostart for them. The [Unit] block also still references graphical-session.target (PartOf/After), making the result inconsistent. If you need a Sway-specific target, that's better done in a Sway-specific drop-in on your side rather than the shipped unit. 🙏

@Alexays Alexays closed this Jul 3, 2026
@leigh123linux

Copy link
Copy Markdown
Author

It targets everything including places it isn't welcomed eg: gnome, cinnamon and kde
You need to make this your number one priority.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants