bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#18132: Time for a smarter dired-guess-shell-alist-default? (dired-x.


From: Howard Melman
Subject: bug#18132: Time for a smarter dired-guess-shell-alist-default? (dired-x.el)
Date: Sat, 23 Oct 2021 13:57:11 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (darwin)

>> xdg-open uses the underlying desktop system's MIME infrastructure. For a
>> GNU system, that would most typically be GNOME, and its "gio open" (or on
>> older systems, gvfs-open) command.
>
> I don't see that shooting away blindly to xdg-open is satisfactory; the
> user should be able to a) know which command is being run before running
> it and b) modify it on the fly.  Maybe I want to open PDF:s first with
> one and then another PDF reader to see if it looks the same, just as I
> would be able to from a graphical file manager.

In the spirit of "we need to add stuff here, without taking
anything away" can I suggest just adding a new dired-do-open
command that calls out to xdg-open on gnu/linux or open on
darwin or windows.  Such a command has been written many
times and people add it to their local configs.  I have it
bound on X in dired and use it far more often than I do M-!.

Such a command emulates what double clicking on an icon does
which most of the time is what a user wants (because it's
configured it do what their most common app need is).

Having emacs provide the command means it could be correct
reguarding shell quoting and other small issues that people
might get wrong on their own.

For those that want more control either in picking the
command that is run or seeing it beforehand, they can use
and configure dired-guess-shell-alist-default.

-- 

Howard






reply via email to

[Prev in Thread] Current Thread [Next in Thread]