Active Topics

 


Reply
Thread Tools
Feathers McGraw's Avatar
Posts: 654 | Thanked: 2,368 times | Joined on Jul 2014 @ UK
#1
Today I was exploring qt dbus methods on my desktop machine using Qt 5 D-Bus Viewer, and it got me wondering if something similar existed for Sailfish.

Searching with zypper found me a package called qt5-qttools-qdbus, which contains the commandline tool qdbus you can use to run dbus commands, and also qdbusviewer:



A little small, but it still works with a touch screen (would have been great with a resistive touchscreen...).

If you want to run these apps from the commandline without typing the full path, you can add this to your .bashrc file:

Code:
# change PATH to include the path of binaries provided by qt5-qttools-qdbus
# e.g. qdbus and qdbusviewer
PATH=$PATH:/usr/lib/qt5/bin/
and then load it:

Code:
source ~/.bashrc
Thought I'd share because it seems like a useful way to discover dbus methods on Sailfish and control apps from scripts - for example, on my desktop I was fiddling around to make Kontact load minimised, which used this command:

Code:
qdbus org.kde.kontact /kontact/MainWindow_1 hide
I'm sure there are similar useful things you could do with this on SFOS.
 

The Following 15 Users Say Thank You to Feathers McGraw For This Useful Post:
Posts: 15 | Thanked: 12 times | Joined on Jun 2012
#2
Thanks for this post, I'm trying to use rockpool so I need qdbus to talk to it.

Unfortunately I can't get the package to install.
Code:
pkcon install qt5-qttools-qdbus
just keeps telling me about unsigned packages, when I type 'y' it goes around in the same loop and no matter now many times I say 'y' it never installs anything.

I've tried to Google but found nothing. Any ideas?
 

The Following User Says Thank You to kombipom For This Useful Post:
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#3
devel-su? or post your error log.
__________________
Telegram | Openrepos | GitHub | Revolut donations
 

The Following User Says Thank You to coderus For This Useful Post:
Posts: 15 | Thanked: 12 times | Joined on Jun 2012
#4
I've tried as normal user and under devel_su and get the same thing. Output of command attached.
Attached Files
File Type: txt output.txt (1.3 KB, 137 views)
 

The Following User Says Thank You to kombipom For This Useful Post:
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#5
so did you enabled installation from untrusted sources in settings?
__________________
Telegram | Openrepos | GitHub | Revolut donations
 

The Following User Says Thank You to coderus For This Useful Post:
Posts: 15 | Thanked: 12 times | Joined on Jun 2012
#6
Yes, untrusted allowed. Developer Mode on. I don't have allow developer updates on as that needs a log in.
 
Posts: 958 | Thanked: 3,426 times | Joined on Apr 2012
#7
Does this have new features that SailDBusViewer doesn't have?
 
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#8
no, this is just common cli tool
__________________
Telegram | Openrepos | GitHub | Revolut donations
 

The Following User Says Thank You to coderus For This Useful Post:
Reply

Tags
d-bus, qdbus, qdbusviewer, sailfish


 
Forum Jump


All times are GMT. The time now is 05:31.