rharish101 / ReGreet

Clean and customizable greeter for greetd
GNU General Public License v3.0
348 stars 16 forks source link

Update documentation #34

Closed Mikilio closed 11 months ago

Mikilio commented 11 months ago

I am running NixOS with greetd. I have done a lot of fiddling to start regreet in a sway session started by greetd, because cage is still unusable to me. What I struggled with the most was getting rid of the 25 sec delay of GTK because it's waiting for answers from dbus (xdg-portal-gtk or something). All this is described in the added Note however the solution described in this link is supposed to work for normal sway sessions it will not work for greetd.

What I figured out is that what is really need was basically to change command that starts sway to this instead:

/path/to/bin/dbus-run-session /path/to/bin/sway --config /path/to/swayConfig

Of course paths don't need to be explicit if they are already in PATH. In the end it doesn't matter if your add stuff to your configuration (that tries to get some envs from dbus) when sway isn't run with dbus to begin with.

In that sense, please verify my solution is indeed the correct thing to do and update the documentation, so no one has to wait for this beautiful software to start ever again.

rharish101 commented 11 months ago

I tried this on my Arch system, but I didn't see any difference. I can add this to the note, however.

EDIT: Did this with commit 8ef03fc8bd15f10e3f22beac4c9a81c5951bb56b.

Mikilio commented 11 months ago

That is surprising indeed maybe there is an overall better way to achieve this.

Actually I noticed that doing exec systemctl --user import-environment at the beginning also works. Maybe it's a thing with NixOS heavy reliance on systemd for environment variables.

rharish101 commented 11 months ago

Try asking the person maintaining the NixOS package. They might have some insights. As I'm using Arch, I might not be the right guy, although Arch probably uses systemd in a similar way.

LtdJorge commented 9 months ago

Thank you @Mikilio, this has also fixed the long wait for me in Gentoo. I still don't know what env was not set or was not being picked up. I'm guessing something to do with the Wayland display, seat, etc. The Wayland ecosystem outside established DEs is still pretty confusing to me.

Just by using dbus-run-session I got almost instant gtkgreet start up. I'll be trying ReGreet next, since it seems a bit more hackable to me, because it's made in Rust :D

Thank you @rharish101 too for linking to this in the Readme, that's how I finally got to fix it.