2 added link to man page; a bit of rephrasing; improved formatting so that horizontal scrolling isn't necessary
source | link

gdbusgdbus is part of glib2 and support bashsupports Bash completions. Here is how to douse it in(on Fedora):

bash
 -4.4$ source /usr/share/bash-completion/completions/gdbus
bash-4.4$ gdbus call --system --dest <TAB><TAB>

This will show all possible destinations. To get a list of the available interfaces DBus exports the org.freedesktop.DBus.ListNames method. You can call it by running:

gdbus call --system --dest org.freedesktop.DBus \
           --object-path /org/freedesktop/DBus  \
           --method org.freedesktop.DBus.ListNames

Unfortunately this leads to unreadable output. Fortunately the output is valid python, so this is possible:

gdbus call --system --dest org.freedesktop.DBus      \
           --object-path /org/freedesktop/DBus       \
           --method org.freedesktop.DBus.ListNames | \
    python -c 'import sys; from pprint importsys, pprint; pprint.pprint(eval(sys.stdin.read()))'

I don't usually do this, but is a nice trick to keep on sleeve. I use gdbus for introspecting and proving concepts before moving to code. The bash completion saves a lot of typing and avoid typos. Would be nice to have gdbus displaying a nicer output.

gdbus is part of glib2 and support bash completions. Here is how to do it in Fedora:

bash
 source /usr/share/bash-completion/completions/gdbus
gdbus call --system --dest <TAB><TAB>

This will show all possible destinations. To get a list of the available interfaces DBus exports org.freedesktop.DBus.ListNames method. You can call it by

gdbus call --system --dest org.freedesktop.DBus --object-path /org/freedesktop/DBus --method org.freedesktop.DBus.ListNames

Unfortunately this leads to unreadable output. Fortunately the output is valid python so this is possible:

gdbus call --system --dest org.freedesktop.DBus --object-path /org/freedesktop/DBus --method org.freedesktop.DBus.ListNames | python -c 'import sys; from pprint import pprint; pprint(eval(sys.stdin.read()))'

I don't usually do this, but is a nice trick to keep on sleeve. I use gdbus for introspecting and proving concepts before moving to code. The bash completion saves a lot of typing and avoid typos. Would be nice to have gdbus displaying a nicer output.

gdbus is part of glib2 and supports Bash completions. Here is how to use it (on Fedora):

bash-4.4$ source /usr/share/bash-completion/completions/gdbus
bash-4.4$ gdbus call --system --dest <TAB><TAB>

This will show all possible destinations. To get a list of the available interfaces DBus exports the org.freedesktop.DBus.ListNames method. You can call it by running:

gdbus call --system --dest org.freedesktop.DBus \
           --object-path /org/freedesktop/DBus  \
           --method org.freedesktop.DBus.ListNames

Unfortunately this leads to unreadable output. Fortunately the output is valid python, so this is possible:

gdbus call --system --dest org.freedesktop.DBus      \
           --object-path /org/freedesktop/DBus       \
           --method org.freedesktop.DBus.ListNames | \
    python -c 'import sys, pprint; pprint.pprint(eval(sys.stdin.read()))'

I don't usually do this, but is a nice trick to keep on sleeve. I use gdbus for introspecting and proving concepts before moving to code. The bash completion saves a lot of typing and avoid typos. Would be nice to have gdbus displaying a nicer output.

1
source | link

gdbus is part of glib2 and support bash completions. Here is how to do it in Fedora:

bash
source /usr/share/bash-completion/completions/gdbus
gdbus call --system --dest <TAB><TAB>

This will show all possible destinations. To get a list of the available interfaces DBus exports org.freedesktop.DBus.ListNames method. You can call it by

gdbus call --system --dest org.freedesktop.DBus --object-path /org/freedesktop/DBus --method org.freedesktop.DBus.ListNames

Unfortunately this leads to unreadable output. Fortunately the output is valid python so this is possible:

gdbus call --system --dest org.freedesktop.DBus --object-path /org/freedesktop/DBus --method org.freedesktop.DBus.ListNames | python -c 'import sys; from pprint import pprint; pprint(eval(sys.stdin.read()))'

I don't usually do this, but is a nice trick to keep on sleeve. I use gdbus for introspecting and proving concepts before moving to code. The bash completion saves a lot of typing and avoid typos. Would be nice to have gdbus displaying a nicer output.