<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - xdg-open does not spawn terminal for Terminal=true"
href="https://bugs.freedesktop.org/show_bug.cgi?id=92514">92514</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>xdg-open does not spawn terminal for Terminal=true
</td>
</tr>
<tr>
<th>Product</th>
<td>Portland
</td>
</tr>
<tr>
<th>Version</th>
<td>1.1.0
</td>
</tr>
<tr>
<th>Hardware</th>
<td>All
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Component</th>
<td>xdg-utils
</td>
</tr>
<tr>
<th>Assignee</th>
<td>portland-bugs@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>t_glaessle@gmx.de
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=118945" name="attach_118945" title="Ad hoc patch to launch terminal">attachment 118945</a> <a href="attachment.cgi?id=118945&action=edit" title="Ad hoc patch to launch terminal">[details]</a></span>
Ad hoc patch to launch terminal
xdg-open does not spawn terminals for desktop files with `Terminal=true`.
For example consider the following configuration:
`~/.local/share/applications/ranger.desktop`:
[Desktop Entry]
Name=ranger
Type=Application
Terminal=true
Exec=ranger %F
`~/.local/share/applications/mimeapps.list`:
[Default Applications]
inode/directory=ranger.desktop
inode/mount-point=ranger.desktop
Then I expect ranger to be opened in a terminal upon running:
xdg-open /
What currently happens is:
(a) if running the command from a non-terminal context, xdg-open tries to
execute ranger without terminal. This errors and xdg-open falls back to execute
mimeopen which ignores mimeapps.list and only looks at defaults.list and
therefore confusingly may use another default.
(b) if running the command within a terminal, ranger is opened in the current
terminal. While this is fine, I think it would be fine as well to spawn a new
terminal.
This applies to xdg-utils 1.1.1.
The attached patch spawns a new terminal asynchronously indiscriminately of
case (a) versus case (b). It uses the TERMINAL environment variable, similar to
what `mimeopen` does.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>