Spec to define the default terminal?

Simon Lees sflees at suse.de
Thu May 25 06:16:03 UTC 2017



On 05/25/2017 12:12 PM, Vladimir Kudrya wrote:
> Hello everyone!
> 
> Any news on this?
> 
> I'll expand my previous proposal of xsession-like approach:
> 
> - Terminal emulators with their exec arguments should be described by
> desktop entries in /usr/share/x-terminal-emulators
> - Preferred terminal is configured in
> ${XDG_CONFIG_[HOME|DIRS]}/[$desktop-]x-terminal-emulator.list (hierarchy
> similar to the one in mime-apps-spec)
> - Format would be a simple newline-separated list of desktop entries.
> - Implementations should choose the first available entry in top
> priority config. Move to next priority config if not found. Last
> priority would be a list generated by `ls /usr/share/x-terminal-emulators`.
> 

We already have the xdg-terminal binary which launches the terminal
based off the currently running desktop. I think a better approach would
be to integrate with that existing infrastructure, it could be modified
for example to check for the existence of a config file in 1 maybe
several dirs (I guess a sysadmin may want to configure a default
terminal for all his users).

That config file would contain the path to the terminal followed by the
exec command. This approach is less secure as someone could modify the
config file without you realising (I guess this could happen anyway).

I don't like the idea of describing exec arguments only somewhere in
/usr, it would mean that if I was working on a machine that I didn't
have root access to and I wanted to use some less popular or new
terminal that hadn't been added to the list yet I wouldn't be able to. I
also wouldn't be able to use a terminal that I had built from source in
my home dir and added to my path.

I also think in the days of the X11 / wayland transition prefixing the
config files with xdg- rather then x- is a better approach, I may be on
my own with that though.

Cheers

> 
> 2015-11-03 16:47, Bastien Nocera пишет:
>> On Wed, 2015-10-21 at 19:30 +0200, Per Olofsson wrote:
>>> On 2015-10-20 15:10, Bastien Nocera wrote:
>>>>> Apparently GNOME removed the UI for choosing terminal so you have
>>>>> to
>>>>> use
>>>>> the gsettings command to change it.
>>>> No, it doesn't have anything to change it because nobody who might
>>>> care
>>>> has made the changes:
>>>> https://bugzilla.gnome.org/show_bug.cgi?id=627943
>>> I believe GNOME 2 had a UI for choosing the terminal emulator. But I
>>> guess the settings UI was completely rewritten in GNOME 3. Sorry.
>>>
>>>>> I was sceptical at first but now I think it might be a good idea,
>>>>> although strictly speaking it is an abuse of MIME types. It is
>>>>> similar
>>>>> to how URIs are handled, with x-scheme-handler/<scheme>.
>>>> Not really. See the bug above.
>>> I can't find any argument in the bug report for why having a MIME
>>> type
>>> for terminals would be more wrong than x-scheme-handler. Only you
>>> stating so :-)
>> Both mime-type and scheme are metadata to the URL. I'd be fine having a
>> "x-scheme-handler/terminal" mime-type added if they could all handle
>> those URLs. They can't though.
>>
>>> But you're right, it is more of a stretch. At least x-scheme-handler
>>> is
>>> about applications opening stuff.
>>>
>> _______________________________________________
>> xdg mailing list
>> xdg at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/xdg
> 
> _______________________________________________
> xdg mailing list
> xdg at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/xdg

-- 

Simon Lees (Simotek)                            http://simotek.net

Emergency Update Team                           keybase.io/simotek
SUSE Linux                           Adelaide Australia, UTC+10:30
GPG Fingerprint: 5B87 DB9D 88DC F606 E489 CEC5 0922 C246 02F0 014B

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/xdg/attachments/20170525/77021d31/attachment.sig>


More information about the xdg mailing list