emacs-devel
[Top][All Lists]
Advanced

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

Re: A feature to go to last edit locations


From: Dr. Arne Babenhauserheide
Subject: Re: A feature to go to last edit locations
Date: Mon, 13 Feb 2023 21:22:28 +0100
User-agent: mu4e 1.8.13; emacs 28.1

Dmitry Gutov <dgutov@yandex.ru> writes:

> On 13/02/2023 21:24, Jean Louis wrote:
>> But Eli said something important, why go somewhere back randomly, but
>> better going where user marked it to need it.
>
> Because by the time the user knows they need to go back, they might
> have missed the opportunity to mark the place.

That’s why I like dumb-jump-back so much. dumb-jump / xref is a
cross-file command. C-M-g gets me to another file. C-M-p gets me back
where I jumped off.

A command that jumps into some other file like go-to-reference or
go-to-definition is a natural recording point. After jumping multiple
times I have a linked list of jump-locations to which I can jump back in
order. As a model that works much better than plain movement recording
in IntelliJ and also somewhat better than edit-locations. (though edit
locations could still be useful — but changing the buffer when going
back through edits can blur the sense which file I’m in at the moment)

If I switch buffers with switch-buffer, I know where I came from. If I
switch with a command, I am likely to quickly jump through multiple
files. So those jump-to-other-file commands are natural recording
points.

When I run xref, this is the point in a file where I’m likely to want to
return to.

Best wishes,
Arne
-- 
Unpolitisch sein
heißt politisch sein,
ohne es zu merken.
draketo.de

Attachment: signature.asc
Description: PGP signature


reply via email to

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