~kennylevinsen

Denmark

https://kl.wtf/

This space intentionally left blank.

Trackers

~kennylevinsen/greetd

Last active 2 months ago

~kennylevinsen/seatd

Last active 4 months ago

~kennylevinsen/wlsunset

Last active 8 months ago

~kennylevinsen/poweralertd

Last active 9 months ago

~kennylevinsen/gtkgreet

Last active 9 months ago

~kennylevinsen/wldash

Last active 2 years ago

#14 Build fails with latest Arch Linux a month ago

Comment by ~kennylevinsen on ~kennylevinsen/gtkgreet

Had forgotten this, just made a 0.8 release.

#44 agreety: do not clear console? 2 months ago

Comment by ~kennylevinsen on ~kennylevinsen/greetd

agetty clears the screen by default before prompting for the login name. See man agetty, description of the "-J, --noclear" flag. The code can be seen here: https://github.com/util-linux/util-linux/blob/1e0ad14b3ac08d855cda6de346a65f9b834e00db/term-utils/agetty.c#L1275

The clearing is actually done by greetd before activating the terminal, not by agreety. It could be made optional, but the current behavior intended to best simulate a normal text-based greeter setup (like agetty+login or ly).

#20 Seatd should support systemd sd_notify 3 months ago

Comment by ~kennylevinsen on ~kennylevinsen/seatd

Hmm, from what I can tell from systemd source, NOTIFY_SOCKET is always a path to the socket, so it should not need parsing. It might need opening though.

For reference, the "READY=1\n" thing was what was implemented for swaylock over in https://github.com/swaywm/swaylock/pull/281, where I believe we made the assumption that you'd be able to get an fd one way or another... Maybe emersion remembers the details?

#20 Seatd should support systemd sd_notify 3 months ago

Comment by ~kennylevinsen on ~kennylevinsen/seatd

The diff would be something like this:

diff --git a/seatd/seatd.c b/seatd/seatd.c
index f88e6c9..5ccf52c 100644
--- a/seatd/seatd.c
+++ b/seatd/seatd.c
@@ -194,7 +194,8 @@ int main(int argc, char *argv[]) {
        log_info("seatd started");
 
        if (readiness != -1) {
-               if (write(readiness, "\n", 1) == -1) {
+               const char ready_str[] = "READY=1\n";
+               if (write(readiness, ready_str, strlen(ready_str)) != strlen(ready_str)) {
                        log_errorf("Could not write readiness signal: %s\n", strerror(errno));
                }
                close(readiness);

There is no need for sendmsg for a simple string, and the service file can specify $NOTIFY_SOCKET as the -n parameter.

#20 Seatd should support systemd sd_notify 3 months ago

Comment by ~kennylevinsen on ~kennylevinsen/seatd

Best I can tell systemd services do not support s6 protocol.

I vaguely remember the two protocols overlapping if READY=1\n is sent.

I think linking to libsystemd should be fine ... and we pull libsystemd in when building seatd with libseat-logind support already

seatd never links with libsystemd - use-cases where one builds and uses libseat with logind support, and use-cases where one builds and runs seatd as a system service do not really overlap - and I do not intend on adding ifdefs and dependencies just to write a fixed string to an fd. :)

#20 Seatd should support systemd sd_notify 4 months ago

enhancement added by ~kennylevinsen on ~kennylevinsen/seatd

#20 Seatd should support systemd sd_notify 4 months ago

seatd added by ~kennylevinsen on ~kennylevinsen/seatd

#20 Seatd should support systemd sd_notify 4 months ago

Comment by ~kennylevinsen on ~kennylevinsen/seatd

seatd offers readiness through the s6 protocol - see -n.

If there is a good usecase, it could possibly be adapted to allow the message to be customized to match the sd-notify format - or maybe just always write READY=1. Linking with libsystemd just for notify seems silly though.

#9 Support for SXMO 4 months ago

Comment by ~kennylevinsen on ~kennylevinsen/wlsunset

Sounds good, closing!

REPORTED RESOLVED CLOSED

#43 greetd + tuigreet permission denied 8 months ago

Comment by ~kennylevinsen on ~kennylevinsen/greetd

REPORTED RESOLVED CLOSED