Sha256: 5f0b6421b207bb9c0871593f5499eea9b33078415c55c47117acf50c75faf764

Contents?: true

Size: 416 Bytes

Versions: 1

Compression:

Stored size: 416 Bytes

Contents

#! /usr/bin/env ruby

# find the library without external help
$:.unshift File.expand_path("../../../lib", __FILE__)

require "dbus"

bus = DBus::SystemBus.instance
driver_svc = bus["org.freedesktop.DBus"]
# p driver_svc
driver_obj = driver_svc["/"]
# p driver_obj
driver_obj.introspect

driver_ifc = driver_obj["org.freedesktop.DBus"]
# p driver_ifc

bus_id = driver_ifc.GetId
puts "The system bus id is #{bus_id}"

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ruby-dbus-0.12.0 examples/simple/get_id.rb