6 releases (breaking)

new 0.10.0 Apr 20, 2024
0.9.0 Jan 5, 2023
0.8.0 Sep 6, 2021
0.6.0 May 16, 2020
0.5.1 Apr 2, 2020

#712 in Encoding

Download history 420/week @ 2024-01-03 475/week @ 2024-01-10 448/week @ 2024-01-17 605/week @ 2024-01-24 551/week @ 2024-01-31 521/week @ 2024-02-07 887/week @ 2024-02-14 814/week @ 2024-02-21 643/week @ 2024-02-28 567/week @ 2024-03-06 628/week @ 2024-03-13 725/week @ 2024-03-20 805/week @ 2024-03-27 822/week @ 2024-04-03 576/week @ 2024-04-10 922/week @ 2024-04-17

3,263 downloads per month

GPL-3.0-only

17KB
200 lines

greetd IPC protocol library

This library implements the greetd IPC protocol.

The library exposes a Request and a Response enum, representing the valid protocol messages. Furthermore, codec implementations are available to serialize these to/from both sync and async readers/writers. The availability of these are controlled by feature flags.

Additional types are part of the different request and response values.

See agreety for a simple example use of this library.

Format

The message format is as follows:

+----------+-------------------+
| len: u32 | JSON payload: str |
+----------+-------------------+

Length is in native byte-order. The JSON payload is a variant of the Request or Response enums.

Request and response types

See Request and Response for information about the request and response types, as well as their serialization.

Dependencies

~0.7–2.6MB
~53K SLoC