darcs

Issue 2209 Automatically detect replace

Title Automatically detect replace
Priority wishlist Status resolved
Milestone Resolved in 2.10.0
Superseder Nosy List jlneder, lukeworth
Assigned To
Topics

Created on 2012-07-15.22:49:45 by lukeworth, last changed 2014-01-20.19:04:23 by noreply.

Messages
msg15871 (view) Author: lukeworth Date: 2012-07-15.22:49:43
Darcs could grow a large set of semantic patch types, especially if they
can be implemented as plugins. It would be very useful for some types to
be able to detect themselves happening, and suggest a specific type of
patch.

e.g. If I rename all occurrences of 'foo' to 'bar' with my text editor,
the 'replace' patch type could detect that a replace has occurred, and
suggest that a replace be recorded rather than line diffs.

e.g. If I rename a file by 'mv a/foo.c b/bar.c; darcs rm a/foo.c; darcs
add b/bar.c', darcs could detect that bar.c has the same contents as
foo.c used to, and suggest a move patch instead of removing and
re-adding every line. (This kind of usage is not stupid - the 3 steps
possibly happened over a long period of time.)
msg17030 (view) Author: gh Date: 2013-09-14.08:09:17
The second case you are describing is actually a particular case of
<http://bugs.darcs.net/issue642>, which Jose Neder is addressing now as
part of his Summer of Code project.
msg17132 (view) Author: noreply Date: 2014-01-20.19:04:21
The following patch sent by Jose Luis Neder <jlneder@gmail.com> updated issue issue2209 with
status=resolved;resolvedin=2.10.0 HEAD

* resolve issue2209: Automatically detect replace 
Ignore-this: 71ebf9ddde0b761b34e5c00eff88b171
This patch add the flag --look-for-replaces to amend-record, record and
whatsnew commands, to automatically detect possible replaces.
History
Date User Action Args
2012-07-15 22:49:45lukeworthcreate
2013-05-29 22:07:03ghsetnosy: + jlneder
2013-09-14 08:09:18ghsetmessages: + msg17030
2014-01-20 19:04:23noreplysetstatus: unknown -> resolved
messages: + msg17132
resolvedin: 2.10.0