darcs

Issue 2132 Hunk editing for revert is buggy.

Title Hunk editing for revert is buggy.
Priority bug Status resolved
Milestone 2.8.0 Resolved in 2.8.0
Superseder Nosy List galbolle, josef.svenningsson, mndrix
Assigned To galbolle
Topics

Created on 2012-01-17.10:00:44 by josef.svenningsson, last changed 2012-03-15.19:46:41 by noreply.

Messages
msg15035 (view) Author: josef.svenningsson Date: 2012-01-17.10:00:43
mkdir foo
cd foo
darcs init
touch file
darcs record --name=quux -a
echo apa >> file
echo bepa >> file
darcs revert

Press 'e' and move the line 'bepa' from BEFORE to AFTER
Then I will get the following UI experience.

hunk ./file 1
+bepa
Shall I revert this change? (1/3)  [ynW...], or ? for more options: n
hunk ./file 1
-bepa
+apa
Shall I revert this change? (2/3)  [ynW...], or ? for more options: n
hunk ./file 2
+bepa
Shall I revert this change? (3/3)  [ynW...], or ? for more options: n
If you don't want to revert after all, that's fine with me!
Finished reverting.

Note that I asked to revert '+bepa' twice, which is really weird. I also
think that the hunk '-bepa +apa' is really weird, intuitively it should 
only show '+apa'.
msg15036 (view) Author: galbolle Date: 2012-01-17.13:55:22
This is a documentation bug: you're supposed to leave the 'BEFORE' part
as-is, thus copying the line rather than moving it. Then the UI does the
right(ish) thing. The semantics of editing the 'BEFORE' part is not
clear (to me), maybe we should disallow it.
msg15044 (view) Author: ganesh Date: 2012-01-19.23:40:20
How would we actually disable it? Just tell users not to touch it and 
ignore anything in it?
msg15186 (view) Author: noreply Date: 2012-02-27.21:37:40
The following patch sent by Florent Becker <florent.becker@ens-lyon.org> updated issue issue2132 with
status=has-patch

* resolve issue2132 ignore edit of 'BEFORE' part for hunk-edit in revert 
Ignore-this: 358955fd6aa8efff3ab44760c40f0c88
msg15341 (view) Author: noreply Date: 2012-03-15.19:46:40
The following patch sent by Florent Becker <florent.becker@ens-lyon.org> updated issue issue2132 with
status=resolved;resolvedin=2.8.0 HEAD

* resolve issue2132 ignore edit of 'BEFORE' part for hunk-edit in revert 
Ignore-this: 358955fd6aa8efff3ab44760c40f0c88
History
Date User Action Args
2012-01-17 10:00:44josef.svenningssoncreate
2012-01-17 13:55:23galbollesetassignedto: galbolle
messages: + msg15036
nosy: + galbolle
2012-01-19 23:40:21ganeshsetmessages: + msg15044
2012-02-24 19:12:04ganeshsetpriority: bug
2012-02-24 20:45:26mndrixsetnosy: + mndrix
2012-02-27 21:37:41noreplysetstatus: unknown -> has-patch
messages: + msg15186
2012-03-15 19:46:41noreplysetstatus: has-patch -> resolved
messages: + msg15341
resolvedin: 2.8.0