[darcs-users] darcs patch: Move a couple of low-level pending bits ... (and 2 more)
me at mornfall.net
Tue Oct 13 16:29:42 UTC 2009
this is first part of a larger change, but I thought I'd send it rather sooner
than later. With darcs-hs, we are maybe halfway through removing SlurpDirectory
from darcs code altogether (maybe a little more).
These patches make another few steps toward that goal. There's still a bunch of
code that needs to be converted:
- Record and Rollback use slurps to do a check on filenames passed, similar to
WhatsNew; this code should ideally be refactored to use a common function
(seems to be a result of copy&paste programming)
- read_checkpoints, which is only used in remove_from_checkpoint_inventory
which *may* be redundant now
- the MatchMonad which I don't quite understand, but it doesn't seem to do
anything too involved wrt slurpies
- Repository.Internal: make_new_pending (should be easy), setScriptsExecutable
(should be easy, too)
- darcs optimize --relink
- darcs move
- darcs add
- darcs diff to copy unrecorded state
Out of these, darcs move and darcs add are going to be the most
tricky. However, when this is done, another big block of code can be
obliterated: slurp_* in Repository.* and the SlurpDirectory modules. This would
do away with most of the tricky IO interleaving that darcs does, too.
I'll work on this as time permits.
Tue Oct 13 12:28:53 CEST 2009 Petr Rockai <me at mornfall.net>
* Move a couple of low-level pending bits to (new) Repository.LowLevel.
Tue Oct 13 12:45:23 CEST 2009 Petr Rockai <me at mornfall.net>
* Port list_* in Darcs.Arguments to Tree (away from Slurpy).
Tue Oct 13 14:02:42 CEST 2009 Petr Rockai <me at mornfall.net>
* Convert contextual patch printing from Slurpy to TreeIO.
This obliterates another major source of SlurpDirectory usage in darcs. I agree
the code has become a little more hairy, although this should be addressable by
a slight refactor of virtualTreeIO and friends in hashed-storage (there's
currently no reasonable way to create a sub-monad in TreeIO).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 79548 bytes
Desc: A darcs patch for your repository!
More information about the darcs-users