* is it possible to «lose» edits when aborting recursive-edits?
@ 2024-01-10 20:54 Uwe Brauer via Emacs development discussions.
2024-01-11 6:42 ` Eli Zaretskii
2024-01-16 8:20 ` Jean Louis
0 siblings, 2 replies; 8+ messages in thread
From: Uwe Brauer via Emacs development discussions. @ 2024-01-10 20:54 UTC (permalink / raw)
To: emacs-devel
Hi
I just edited for around 40 min a file, and wanted to commit the
changes. I noticed that I had 2 or three recursive-edits level, most
likely the result of some errors that occurred when I executed some
reftex and latex commands (I do not recall the reasons).
Be it as it may: I hit C-] as I always do,
committed but then realized that some of my changes were not committed,
indeed they seem to have vanished.
Any idea what happened? I vaguely remember something similar some years
ago.
Regards
Uwe Brauer
--
I strongly condemn Hamas heinous despicable pogroms/atrocities on Israel
I strongly condemn Putin's war of aggression against Ukraine.
I support to deliver weapons to Ukraine's military.
I support the EU and NATO membership of Ukraine.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: is it possible to «lose» edits when aborting recursive-edits?
2024-01-10 20:54 is it possible to «lose» edits when aborting recursive-edits? Uwe Brauer via Emacs development discussions.
@ 2024-01-11 6:42 ` Eli Zaretskii
2024-01-11 7:02 ` Uwe Brauer
2024-01-16 8:20 ` Jean Louis
1 sibling, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2024-01-11 6:42 UTC (permalink / raw)
To: Uwe Brauer; +Cc: emacs-devel
> Date: Wed, 10 Jan 2024 21:54:09 +0100
> From: Uwe Brauer via "Emacs development discussions." <emacs-devel@gnu.org>
>
> I just edited for around 40 min a file, and wanted to commit the
> changes. I noticed that I had 2 or three recursive-edits level, most
> likely the result of some errors that occurred when I executed some
> reftex and latex commands (I do not recall the reasons).
>
> Be it as it may: I hit C-] as I always do,
> committed but then realized that some of my changes were not committed,
> indeed they seem to have vanished.
What do you mean by "not committed"?
In general, please describe in more detail what you did before and
after C-], as these details matter for trying to figure out what
happened in your case. (Your evident assumption that there's some
obvious aspect of C-] that will immediately yield an answer is
incorrect, since C-] aborts the current command, but cannot possibly
undo the effect of previous commands on buffer text.)
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: is it possible to «lose» edits when aborting recursive-edits?
2024-01-11 6:42 ` Eli Zaretskii
@ 2024-01-11 7:02 ` Uwe Brauer
2024-01-11 9:02 ` Eli Zaretskii
0 siblings, 1 reply; 8+ messages in thread
From: Uwe Brauer @ 2024-01-11 7:02 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: Uwe Brauer, emacs-devel
[-- Attachment #1: Type: text/plain, Size: 2011 bytes --]
>>> "EZ" == Eli Zaretskii <eliz@gnu.org> writes:
>> Date: Wed, 10 Jan 2024 21:54:09 +0100
>> From: Uwe Brauer via "Emacs development discussions." <emacs-devel@gnu.org>
>>
>> I just edited for around 40 min a file, and wanted to commit the
>> changes. I noticed that I had 2 or three recursive-edits level, most
>> likely the result of some errors that occurred when I executed some
>> reftex and latex commands (I do not recall the reasons).
>>
>> Be it as it may: I hit C-] as I always do,
>> committed but then realized that some of my changes were not committed,
>> indeed they seem to have vanished.
> What do you mean by "not committed"?
The did not appear in the commit.
Here is an example
Paragraph 1:
New: blabla
Paragraph: 2
New: more blabla blabla
C-]
Commit via vc-next-action
All new parts paragraph 1 are not part of the commit.
I suspect they «disappeared» when I hit C-]
Possible explanation
Paragraph 2
New more blabla
Was written on the top-level but Paragraph 1 on some second or higher
recursive-level and disappeared after having hit C-]
I just run an experiment. I cannot reproduce my hypothesis
> In general, please describe in more detail what you did before and
> after C-], as these details matter for trying to figure out what
> happened in your case.
Yes of course, I wish I could, my hope was that somebody had seen
something similar in the past
I now set, locally
%%% vc-make-backup-files: t
> (Your evident assumption that there's some
> obvious aspect of C-] that will immediately yield an answer is
> incorrect, since C-] aborts the current command, but cannot possibly
> undo the effect of previous commands on buffer text.)
--
I strongly condemn Hamas heinous despicable pogroms/atrocities on Israel
I strongly condemn Putin's war of aggression against Ukraine.
I support to deliver weapons to Ukraine's military.
I support the EU and NATO membership of Ukraine.
[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5673 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: is it possible to «lose» edits when aborting recursive-edits?
2024-01-11 7:02 ` Uwe Brauer
@ 2024-01-11 9:02 ` Eli Zaretskii
2024-01-11 10:01 ` Uwe Brauer
2024-01-11 17:51 ` Uwe Brauer via Emacs development discussions.
0 siblings, 2 replies; 8+ messages in thread
From: Eli Zaretskii @ 2024-01-11 9:02 UTC (permalink / raw)
To: Uwe Brauer; +Cc: emacs-devel
> From: Uwe Brauer <oub@mat.ucm.es>
> Cc: Uwe Brauer <oub@mat.ucm.es>, emacs-devel@gnu.org
> Date: Thu, 11 Jan 2024 08:02:10 +0100
>
> >>> "EZ" == Eli Zaretskii <eliz@gnu.org> writes:
>
> > What do you mean by "not committed"?
>
> The did not appear in the commit.
>
> Here is an example
>
> Paragraph 1:
>
> New: blabla
>
> Paragraph: 2
>
> New: more blabla blabla
>
> C-]
>
> Commit via vc-next-action
>
> All new parts paragraph 1 are not part of the commit.
Sorry, this is still not detailed enough: how did those "new parts"
appear, and in which buffer? IOW, what did you do to make these new
parts appear wherever they appeared?
> Possible explanation
>
> Paragraph 2
>
> New more blabla
>
> Was written on the top-level but Paragraph 1 on some second or higher
> recursive-level and disappeared after having hit C-]
I'm asking for more details about the "was written" part.
It will be the simplest if you describe the commands you invoked
before C-], even if it's just typing some text. IOW, a complete
recipe of the issue.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: is it possible to «lose» edits when aborting recursive-edits?
2024-01-11 9:02 ` Eli Zaretskii
@ 2024-01-11 10:01 ` Uwe Brauer
2024-01-11 17:51 ` Uwe Brauer via Emacs development discussions.
1 sibling, 0 replies; 8+ messages in thread
From: Uwe Brauer @ 2024-01-11 10:01 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: Uwe Brauer, emacs-devel
[-- Attachment #1: Type: text/plain, Size: 240 bytes --]
> Sorry, this is still not detailed enough: how did those "new parts"
> appear, and in which buffer? IOW, what did you do to make these new
> parts appear wherever they appeared?
I think I need a MWE. Once I find one, I will come back.
[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5673 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: is it possible to «lose» edits when aborting recursive-edits?
2024-01-11 9:02 ` Eli Zaretskii
2024-01-11 10:01 ` Uwe Brauer
@ 2024-01-11 17:51 ` Uwe Brauer via Emacs development discussions.
1 sibling, 0 replies; 8+ messages in thread
From: Uwe Brauer via Emacs development discussions. @ 2024-01-11 17:51 UTC (permalink / raw)
To: emacs-devel
[-- Attachment #1: Type: text/plain, Size: 1166 bytes --]
> Sorry, this is still not detailed enough: how did those "new parts"
> appear, and in which buffer? IOW, what did you do to make these new
> parts appear wherever they appeared?
> I'm asking for more details about the "was written" part.
It happened again. In a latex file I currently edited, parts of edits
disappeared. Fortunately I had backup-each-save activated, which makes a
backup copy (in a separate directory) of the whole file each time the
file is saved.
It looks like
36K ene 11 18:23 new-report-vs2.tex-2024_01_11_18_23_52 edits lost
36K ene 11 18:23 new-report-vs2.tex-2024_01_11_18_23_43 edits lost
36K ene 11 18:23 new-report-vs2.tex-2024_01_11_18_23_41 edits lost
36K ene 11 18:22 new-report-vs2.tex-2024_01_11_18_22_37 edits lost
36K ene 11 18:21 new-report-vs2.tex-2024_01_11_18_21_27 Good file
I have to finish this report and then I try to come up with a MWE.
--
I strongly condemn Hamas heinous despicable pogroms/atrocities on Israel
I strongly condemn Putin's war of aggression against Ukraine.
I support to deliver weapons to Ukraine's military.
I support the EU and NATO membership of Ukraine.
[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5673 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: is it possible to «lose» edits when aborting recursive-edits?
2024-01-10 20:54 is it possible to «lose» edits when aborting recursive-edits? Uwe Brauer via Emacs development discussions.
2024-01-11 6:42 ` Eli Zaretskii
@ 2024-01-16 8:20 ` Jean Louis
2024-01-16 14:50 ` [External] : " Drew Adams
1 sibling, 1 reply; 8+ messages in thread
From: Jean Louis @ 2024-01-16 8:20 UTC (permalink / raw)
To: emacs-devel
* Uwe Brauer via "Emacs development discussions. <emacs-devel@gnu.org> [2024-01-11 08:55]:
>
> Hi
>
> I just edited for around 40 min a file, and wanted to commit the
> changes. I noticed that I had 2 or three recursive-edits level, most
> likely the result of some errors that occurred when I executed some
> reftex and latex commands (I do not recall the reasons).
>
> Be it as it may: I hit C-] as I always do,
> committed but then realized that some of my changes were not committed,
> indeed they seem to have vanished.
I have similar problem. I would like to be able:
- to detect pending recursive edits, as not to lose them
- to be able to walk over buffers of recursive edits.
Jean
Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns
In support of Richard M. Stallman
https://stallmansupport.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* RE: [External] : Re: is it possible to «lose» edits when aborting recursive-edits?
2024-01-16 8:20 ` Jean Louis
@ 2024-01-16 14:50 ` Drew Adams
0 siblings, 0 replies; 8+ messages in thread
From: Drew Adams @ 2024-01-16 14:50 UTC (permalink / raw)
To: Jean Louis, emacs-devel@gnu.org
> > I had 2 or three recursive-edits level...
> > I hit C-] as I always do, committed but
> > then realized that some of my changes
> > were not committed...
>
> I have similar problem. I would like to be able:
>
> - to detect pending recursive edits, as not to lose them
> - to be able to walk over buffers of recursive edits.
1. The little library `rec-edit.el' can likely
help with the former.
code:
https://www.emacswiki.org/emacs/download/rec-edit.el
description:
https://www.emacswiki.org/emacs/RecursiveEdit#rec-edit.el
2. The latter should be easy to implement:
Iterate over `buffer-list'. You can use a
hook such as `kill-emacs-query-functions'.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2024-01-16 14:50 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-10 20:54 is it possible to «lose» edits when aborting recursive-edits? Uwe Brauer via Emacs development discussions.
2024-01-11 6:42 ` Eli Zaretskii
2024-01-11 7:02 ` Uwe Brauer
2024-01-11 9:02 ` Eli Zaretskii
2024-01-11 10:01 ` Uwe Brauer
2024-01-11 17:51 ` Uwe Brauer via Emacs development discussions.
2024-01-16 8:20 ` Jean Louis
2024-01-16 14:50 ` [External] : " Drew Adams
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.