[darcs-users] Merge two recorded changes

Tommy Pettersson ptp at lysator.liu.se
Tue Apr 15 19:55:00 UTC 2008


On Tue, Apr 15, 2008 at 07:32:07PM +0100, Ashley Moran wrote:
> 
> 4   unrecorded changes
>   \ /
>    3
>    |
>    2
>    |
>    1
> 

I would probably do something like this:

  - backup the modified files in bak1
  - revert all unrecorded changes
  - backup files modified by 4 in bak2
  - obliterate 4
  - unrecord 3 and amend 2 with 3's changes
  - restore from bak2
  - record 4 as a new patch
  - restore from bak1

This method of backup-obliterate-amend-restore is sometimes
faster than multiple unrecords and interactive records,
especially if the interactive records are tedious.


I don't know if darcs makes you addicted to "a perfect history",
or if it just makes you more aware of the value of good
changesets. If we make an effort to make our code
understandable, wouldn't it make sense to also make an effort to
make our changes to it understandable?


-- 
Tommy Pettersson <ptp at lysator.liu.se>


More information about the darcs-users mailing list