Rebus

An Elixir implementation of the D-Bus message protocol.

Rebus provides a clean, Elixir-native interface for communicating over D-Bus, the inter-process communication (IPC) and remote procedure call (RPC) mechanism that is standard on Linux desktop systems.

Features

Quick Start

# Connect to a D-Bus endpoint
{:ok, conn} = Rebus.connect(:session)

# Add a signal handler to receive D-Bus signals
ref = Rebus.add_signal_handler(conn)

# Create and send a D-Bus message
{:ok, message} = Rebus.Message.new(:method_call,
  path: "/com/example/Object",
  interface: "com.example.Interface", 
  member: "TestMethod",
  body: [42, "hello"],
  signature: "is"
)

# Clean up when done
Rebus.delete_signal_handler(conn, ref)

Architecture

Rebus is built with a modular architecture:

Connection Types

Rebus supports connecting to different types of D-Bus endpoints:

Message Types

Rebus supports all D-Bus message types:

D-Bus Compliance

Rebus implements the D-Bus specification including:

Testing

Rebus includes comprehensive testing infrastructure:

Installation

Add rebus to your list of dependencies in mix.exs:

def deps do
  [
    {:rebus, "~> 0.1.0"}
  ]
end

Documentation

Documentation can be generated with ExDoc:

mix docs

The generated documentation includes comprehensive API references, examples, and implementation details.

License

This project is licensed under the MIT License.

Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin feature/my-new-feature)
  5. Create a new Pull Request

Make sure to run the test suite before submitting:

mix test
mix test --cover  # With coverage reporting