13 releases (7 stable)

new 4.0.1 Feb 17, 2024
3.1.1 May 16, 2023
3.1.0 Dec 6, 2022
3.0.0 Sep 13, 2022
1.0.0 Jan 2, 2021

#895 in Unix APIs

Download history 18/week @ 2023-11-01 18/week @ 2023-11-08 11/week @ 2023-11-15 29/week @ 2023-11-22 28/week @ 2023-11-29 28/week @ 2023-12-06 32/week @ 2023-12-13 16/week @ 2023-12-20 27/week @ 2023-12-27 8/week @ 2024-01-03 7/week @ 2024-01-10 10/week @ 2024-01-17 21/week @ 2024-01-24 38/week @ 2024-01-31 10/week @ 2024-02-07 282/week @ 2024-02-14

352 downloads per month

MIT license

1MB
23K SLoC

zbus_xmlgen

A binary crate that provides a developer tool to generate zbus-based Rust code from D-Bus XML interface descriptions. It can be used to generate the code directly from a running D-Bus system, session or other service, or using a preexisting XML file for input.

Status: Stable.

Usage

$ cargo install zbus_xmlgen
$ zbus-xmlgen system org.freedesktop.login1 /org/freedesktop/login1
$ zbus-xmlgen session org.freedesktop.ScreenSaver /org/freedesktop/ScreenSaver
$ zbus-xmlgen address unix:abstract=/home/user/.cache/ibus/dbus-fpxKwgbJ org.freedesktop.IBus /org/freedesktop/IBus
$ zbus-xmlgen file interface.xml # Use '-' for stdin.

lib.rs:

This code was generated by {} {} from D-Bus introspection data. Source: {}.

You may prefer to adapt it, instead of using it verbatim.

More information can be found in the [Writing a client proxy] section of the zbus documentation.

following zbus API can be used:

Consequently {} did not generate code for the above interfaces. [Writing a client proxy]: https://dbus2.github.io/zbus/client.html [D-Bus standard interfaces]: https://dbus.freedesktop.org/doc/dbus-specification.html#standard-interfaces,

Dependencies

~12–25MB
~362K SLoC