emacs-devel
[Top][All Lists]
Advanced

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

Re: Friendlier dired experience [CODE INCLUDED]


From: Stefan Monnier
Subject: Re: Friendlier dired experience [CODE INCLUDED]
Date: Mon, 09 Nov 2020 18:20:13 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

> environment variables. It's a limitation however that the values are only
> set (right?) when you go from the diredc buffers to the shell again, using
> the special command. It would be super cool if the shell just "knew",
> without diredc needing to set those things explicitly. Could Emacs'
> different shells and terminals have this ability automatically by using
> some pre-processing of each command invocation, looking for open Dired
> windows in the same frame?

I don't think this can be done "right" (actually in general even what
diredc provides can't be done reliably without re-launching a new shell)
by make the shell somehow aware of "where we are" (it would require
a much tighter integration between the shell and Emacs than what's
currently available).
I can see two ways to do it:
1- ask the users to setup some kind of "support code" in their shell
   which implements a particular communication protocol with Emacs (and
   provide implementations for the most popular shells).
2- keep all the processing on Emacs's side, i.e. add special notations
   that can be used in the *shell* buffer and that are expanded by Emacs
   before sending them to the shell.
Option 2 is probably the easiest, but it may get tricky to find a good
syntax for it that's lightweight enough and doesn't get too much in the
way of normal use.  I don't think option 2 can work with `M-x term`, OTOH.

> Did not try them but like others, I felt it might be better to integrate
> with the normal bookmark functionality in some way. A command that simply
> filters out the existing bookmarks that point to directories should not be
> hard to add to Dired, or simply make part of selecting a directory
> regardless of where you are in Emacs.

BTW, I remember thinking that it would be nice/natural to allow
specifying a (file) bookmark name when doing `C-x C-f`, and similarly
`C-x C-d` could allow specifying a (directory) bookmark.

> Resilient dedicated dual-pane frame
>
> I liked this and I used the default keybinding (S-f11). I also felt we
> could make the same thing or something very similar using Winner, the new
> tab functionality, or some of the other ways we can work with window
> configurations. I get that a lot of work has been put into making this, as
> the author says, resilient, and I don't want to down-play that.

I don't know what diredc currently uses, but Emacs has grown the notion
of "Atomic Windows" (see the Info doc, or `display-buffer-in-atom-window`)
which might also be a good fit for diredc (or not: I haven't used it
enough nor know diredc enough to be sure).


        Stefan




reply via email to

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