Saturday, November 9, 2013

Open bitcoin URLs in firefox with Multibit (Ubuntu 12.10 with Gnome-Shell)

Having created Bitcoin donation URLS for my OpenSource projects MyExpenses and SendFithFtp, I tried to find out how to make Firefox open the bitcoin URLs with Multibit.
I am running Ubuntu 12.10. with Gnome Shell, and after some experiments, the following worked:
Multibit creates a menu entry at ~/.local/share/applications/MultiBit\ 0.5.14-1382603328396.desktop

Modify the file to make it handle URLs:

[Desktop Entry]
Categories=
Comment=MultiBit 0.5.14
Comment[de]=MultiBit 0.5.14
Encoding=UTF-8
Exec=/usr/bin/java -jar /home/michael/MultiBit-0.5.14/multibit-exe.jar %u
GenericName=
GenericName[de]=
Icon=/home/michael/MultiBit-0.5.14/multibit48.png
MimeType=x-scheme-handler/bitcoin
Name=MultiBit 0.5.14
Name[de]=MultiBit 0.5.14
Path=/home/michael/MultiBit-0.5.14
ServiceTypes=
SwallowExec=
SwallowTitle=
Terminal=
TerminalOptions=
Type=Application
URL=
X-KDE-SubstituteUID=false
X-KDE-Username=root

and register it with:

xdg-desktop-menu install --novendor ~/.local/share/applications/MultiBit\ 0.5.14-1382603328396.desktop

When clicking in Firefox on a link to a Bitcoin URL, and you get prompted for selecting an application to open the URL with, select /usr/open/xdg-open .

Multibit unfortunatley only handles the URL correctly, when it is already running.

No comments:

Post a Comment