xdg-open is not mate compatible
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
| Ubuntu MATE |
Medium
|
Unassigned | ||
| Xdg-utils |
Fix Released
|
Unknown
|
||
| xdg-utils (Ubuntu) |
Undecided
|
Unassigned |
Bug Description
I had to modify /usr/bin/xdg-open to duplicate the gnome parts and replace /gnome/mate/. Some applications like chrome/chromium open their file using xdg-open.
Linux Mint 13 RC mate edition
Related branches
Robert Evans (robert-evans) wrote : | #1 |
Rob Gardner (robmatic) wrote : | #2 |
> To be more rigorous, use
> elif [ x"$MATE_
Trouble with that is that the case statement following the call to detectDE doesn't have a case for mate, so it falls into the "unknown desktop environment" case.
Robert Evans (robert-evans) wrote : | #3 |
Perhaps I should have said "...That allows xgd-utils scripts to contain functions (which you will need to code yourself) for Mate separately."!
Rob Gardner (robmatic) wrote : | #4 |
Well, it looks like the linuxmint/mate guys picked up your suggestion to set DE=mate but didn't take it any further. The result is that my new lmde system gives me this:
rob $ xdg-settings get default-web-browser
xdg-settings: unknown desktop environment
Perhaps could you add some appropriate person to this bug's notification list?
Robert Evans (robert-evans) wrote : | #5 |
That surprises me. What version of xdg-utils are you installing? I get
xdg-utils Version: 1.1.0~rc1-2ubuntu6
if I apt-get from the standard Mint repository, and that version contains no Mate amendments at all.
But the "unoffical patch" I attached to my initial comment contained the required Mate routines.
(If I knew how to submit these things properly, I would.)
I'm attaching a tar of amended scripts. If you're adept at building your own deb files, you can use these to create a new xdg-utils deb file until an official version is produced. Alternatively, just place the scripts in /usr/bin.
Rob Gardner (robmatic) wrote : | #6 |
My xdg-utils is:
Version: 1.1.0~rc1+
Note that I am running LMDE, which may account for the differing version?
Anyhow, I see that you've got a statement in detectDE that sets DE=gnome if mate is detected, which is pretty much the same thing I did to fix my version. So it sounds like you've got this covered, and the only question is why did my mint install come with a broken version of xdg-settings, and can I expect a future update to fix this, or will I have to manually fix it with each update? :-(
In any case, thank you for your efforts and responses.
malheum (maxheise) wrote : | #7 |
Hello,
I ran across this problem too when I tried to open a bittorrent magnet link from google chrome. I expected the magnet link to open in transmission-gtk, which did not happen.
I read the a nice description of the problem here http://
And then added this little bit of code to /usr/bin/xdg-open. Basically I added a entry for mate in the finally case statement in xdg-open and then copied the gnome open_gnome to open_mate and changed the line open_gnome to open_mate. Patch made with diff -u attached.
case "$DE" in
mate)
open_mate "$url"
;;
kde)
open_kde "$url"
;;
gnome)
open_gnome "$url"
;;
xfce)
open_xfce "$url"
;;
lxde)
open_lxde "$url"
;;
generic)
open_generic "$url"
;;
*)
exit_
;;
esac
open_mate()
{
if gvfs-open --help 2>/dev/null 1>&2; then
gvfs-open "$1"
else
mate-open "$1"
fi
if [ $? -eq 0 ]; then
else
fi
}
BR.
Bill (hudacek) wrote : | #8 |
Seems like a no-brainer. Why is this still 'undecided'?
I've put the changes in place and put a hold on xdg-utils in Mint 14 until this eventually is addressed. I hope no security issues come up in the meantime :-/
Steve Leonard (sleonard76) wrote : | #9 |
For those looking for a quick & dirty solution until this patch is released, put
export GNOME_DESKTOP_
in ~/.bashrc. (Warning: May have undesired side effects)
I can't believe this bug is still around. I am running Mate on Fedora 19 in January 2014 and xdg-email and its' friends still don't
know about Mate.
I added this:
export GNOME_DESKTOP_
and added mate to the detection routine for Gnome and it ***seems*** to work.
My favorite fix is:
http://
2014/1/21 Frank_McCormick <email address hidden>
> I added this:
>
> export GNOME_DESKTOP_
>
>
> and added mate to the detection routine for Gnome and it ***seems*** to
> work.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https:/
>
> Title:
> xdg-open is not mate compatible
>
> Status in The Linux Mint Distribution:
> New
>
> Bug description:
> I had to modify /usr/bin/xdg-open to duplicate the gnome parts and
> replace /gnome/mate/. Some applications like chrome/chromium open
> their file using xdg-open.
>
> Linux Mint 13 RC mate edition
>
> To manage notifications about this bug go to:
> https:/
>
On 21/01/14 03:55 AM, Leo wrote:
> My favorite fix is:
> http://
>
>
> 2014/1/21 Frank_McCormick <email address hidden>
>
>> I added this:
>>
>> export GNOME_DESKTOP_
>>
>>
>> and added mate to the detection routine for Gnome and it ***seems*** to
>> work.
>>
>> --
>> You received this bug notification because you are subscribed to the bug
>> report.
>> https:/
>>
>> Title:
>> xdg-open is not mate compatible
>>
>> Status in The Linux Mint Distribution:
>> New
>>
>> Bug description:
>> I had to modify /usr/bin/xdg-open to duplicate the gnome parts and
>> replace /gnome/mate/. Some applications like chrome/chromium open
>> their file using xdg-open.
>>
That also works. Thanks. I still think it's unbelievable this
bug has hung around this long :)
Leo (leo4ward) wrote : | #14 |
Using
+open_mate()
+{
+ if gvfs-open --help 2>/dev/null 1>&2; then
+ gvfs-open "$1"
+ else
+ mate-open "$1"
+ fi
+
+ if [ $? -eq 0 ]; then
+ exit_success
+ else
+ exit_failure_
+ fi
+}
makes it work better with aplications like dropbox also (launch caja
instead of nautilus for example)
2014/1/21 Frank_McCormick <email address hidden>:
> On 21/01/14 03:55 AM, Leo wrote:
>> My favorite fix is:
>> http://
>>
>>
>> 2014/1/21 Frank_McCormick <email address hidden>
>>
>>> I added this:
>>>
>>> export GNOME_DESKTOP_
>>>
>>>
>>> and added mate to the detection routine for Gnome and it ***seems*** to
>>> work.
>>>
>>> --
>>> You received this bug notification because you are subscribed to the bug
>>> report.
>>> https:/
>>>
>>> Title:
>>> xdg-open is not mate compatible
>>>
>>> Status in The Linux Mint Distribution:
>>> New
>>>
>>> Bug description:
>>> I had to modify /usr/bin/xdg-open to duplicate the gnome parts and
>>> replace /gnome/mate/. Some applications like chrome/chromium open
>>> their file using xdg-open.
>>>
>
>
> That also works. Thanks. I still think it's unbelievable this
> bug has hung around this long :)
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https:/
>
> Title:
> xdg-open is not mate compatible
>
> Status in The Linux Mint Distribution:
> New
>
> Bug description:
> I had to modify /usr/bin/xdg-open to duplicate the gnome parts and
> replace /gnome/mate/. Some applications like chrome/chromium open
> their file using xdg-open.
>
> Linux Mint 13 RC mate edition
>
> To manage notifications about this bug go to:
> https:/
Launchpad Janitor (janitor) wrote : | #15 |
Status changed to 'Confirmed' because the bug affects multiple users.
Changed in ubuntu: | |
status: | New → Confirmed |
asavah (irherder) wrote : | #16 |
Also affects all ubuntu versions up to date.
Ubuntu 14.10 is affected too.
The attachment "unofficial patch for xdg-utils scripts." seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.
[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]
tags: | added: patch |
Launchpad Janitor (janitor) wrote : | #18 |
Status changed to 'Confirmed' because the bug affects multiple users.
Changed in xdg-utils (Ubuntu): | |
status: | New → Confirmed |
affects: | ubuntu-mate → xdg-utils (Ubuntu) |
bedfojo (commercial-johnbedford) wrote : | #19 |
See upstream : https:/
It may be that xdg-utils v1.1.0-rc2 is patched.
Any chance of Ubuntu updating xdg-utils to v1.1.0-rc2 or simply carrying the patch if not?
Launchpad Janitor (janitor) wrote : | #20 |
Status changed to 'Confirmed' because the bug affects multiple users.
Changed in xdg-utils (Ubuntu): | |
status: | New → Confirmed |
affects: | xdg-utils (Ubuntu) → ubuntu-mate |
affects: | ubuntu → xdg-utils (Ubuntu) |
Changed in xdg-utils: | |
status: | Unknown → New |
Changed in ubuntu-mate: | |
importance: | Undecided → Medium |
gravy45 (gravy45) wrote : | #21 |
This is the patch I put together for Ubuntu MATE 15.04, xdg-open, and it seems to take care of the issue as stated in the title. Am unsure where else xdg-open is used but it has been tested with Virtualbox and Transmission. Would like advice on how to test it more properly to determine if it can be proposed as a solution.
Martin Wimpress (flexiondotorg) wrote : | #22 |
A bug has been raised to update xdg-utils with MATE support here:
* https:/
A version of xdg-utils that includes MATE support has been published to the following PPAs:
* https:/
* https:/
* https:/
* https:/
Anyone running Ubuntu MATE 14.04 will automatically get the updated xdg-utils. Anyone running Ubuntu MATE 14.10 or 15.04 will need to add the appropriate PPA above.
Launchpad Janitor (janitor) wrote : | #23 |
Changed in xdg-utils (Ubuntu): | |
status: | Confirmed → Fix Released |
Changed in ubuntu-mate: | |
status: | Confirmed → Fix Released |
Changed in xdg-utils: | |
status: | New → Fix Committed |
Changed in xdg-utils: | |
status: | Fix Committed → Fix Released |
no longer affects: | linuxmint |
In fact, none of the xdg-utils scripts work with Mate. Generally they should treat Mate as GNOME, but they fail to recognise it. DESKTOP_ SESSION_ ID" != x"" ]; then DE=gnome; DESKTOP_ SESSION_ ID" != x"" ]; then DE=gnome;
There's a detectDE function which checks for GNOME...
elif [ x"$GNOME_
but is should also check for Mate ...
elif [ x"$MATE_
That will make the xdg-utils treat Mate as GNOME.
To be more rigorous, use DESKTOP_ SESSION_ ID" != x"" ]; then DE=mate;
elif [ x"$MATE_
That allows xgd-utils scripts to contain functions for Mate separately.
These scripts contain detectDE
xdg-desktop-icon, xdg-desktop-menu, xdg-email, xdg-icon-resource, xdg-mime, xdg-open, xdg-screensaver, xdg-settings
but only
xdg-email, xdg-mime, xdg-open, xdg-screensaver and xdg-settings use it to determine which routines to call.
This bug is pretty fundamental to Mint. For example, mintwelcome uses xdg-open to call the browser to display its
links. If xdg-open doesn't work properly, mintwelcome launches chrome but won't close and stays in focus hiding the
help page you've just launched. With amended xdg-utils, mintwelcome launces firefox or chrome as appropriate and
"Close" works properly.
I'm attaching patches which seem to work. But I'm not sure that I've understood what xdg-screensaver is supposed todo and xdg-settings just uses the GNOME functions.