LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices


Reply
  Search this Thread
Old 10-19-2012, 09:44 AM   #1
mickael.cruz
LQ Newbie
 
Registered: Oct 2012
Posts: 2

Rep: Reputation: Disabled
xdg-open doesn't recognize custom protocol


Hello everyone,

I am trying to register a custom protocol handler in Ubuntu. I followed all the steps I found on google but it still isn't working.

1. I created the .desktop file and put it in ~/.local/share/applications. Here are the contents of this file :

[Desktop Entry]
Type=Application
Encoding=UTF-8
Name=Arya
Exec=/home/mickael/pixeon/pixviewerng/bin/arya %U
Icon=/home/mickael/pixeon/pixviewerng/bin/icon.png
Terminal=false
MimeType=x-scheme-handler/pixeon

2. I ran xdg-mime to register my protocol. Here is the exact command I ran :

xdg-mime default ~/.local/share/applications/arya.desktop x-scheme-handler/pixeon

3. I am now trying to open my custom protocol, here what I run :

xdg-open pixeon:teste

And I get the following error : gvfs-open: pixeon:///teste: error opening location: The specified location is not supported.

I also tried registering my protocol using gconftool. All values seem set correctly (checking with gconf-editor) but the protocol doesn't work either. I even tried registering it in firefox (about:config) but it didn't work either.
When I double click on my desktop file, the app launches, so the error isn't with the desktop file contents. There must be something obvious that I'm missing.

Can someone help me?
 
Old 10-25-2012, 05:09 AM   #2
mickael.cruz
LQ Newbie
 
Registered: Oct 2012
Posts: 2

Original Poster
Rep: Reputation: Disabled
I found out what was wrong... the xdg-mime command takes the name of the desktop file, not his path.
So the correct command was :

xdg-mime default arya.desktop x-scheme-handler/pixeon
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] xdg-open: no method available for opening Amdx2_x64 Programming 3 12-13-2017 11:00 PM
a weird xdg-open issue Oxpoto Linux - Software 0 07-23-2011 03:56 AM
Firefox doesn't know how to open this address, because the protocol (skype) isn't ass junovo Ubuntu 2 01-24-2011 08:47 AM
xdg-open, gnome-open or kde(4?)-open??? akamikeym Programming 0 08-03-2010 08:54 AM
configure: error: The xdg python module is required (pyxdg or python-xdg) Sargalus Linux - Software 7 03-24-2010 07:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 11:25 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration