absolute directories

Posted on 4 March 2006
Tags:

Two things: got the absolute directories tests running, although I had to hack them up a bit to fix what seems to be darcs bitrot and weird perl. Hope my modifications aren't actually breaking the tests.

Also, I've been going over my patch a little more thoroughly, and have found a few bugs. End result is that patch deux is smaller and cleaner. I'm still not entirely sure if it's correct though, and am hoping for some review from fellow developers. Here's the issues with my patch that I've fixed:
  1. Changes.lhs - was not accounting for the fact that repodir could be relative path; fixed by generalising fix_filepaths_here to fix_filepaths_wrt somerepo, where fix_filepaths_wrt has some extra smarts for detecting what kind of path the current repository is
  2. DarcsCommands.lhs - forgot that ghc 6.2.2 does not have canonicalizePath; tough luck, got rid of code which canonicalizes all the absolute paths. Disadvantage is that now, absolute paths detection doesn't always work. Advantage is that the code is a bit tidier and the patch is smaller
  3. Apply.lhs - was needlessly performing the absolute path conversion
  4. FilePathUtils.lhs - was not producing the right error message, and was not strict enough on what kind of repository paths it expects

Sigh... these aren't fixes to darcs, mind you. They're fixes to my patch, which were supposed to fix darcs.

Ok, wow, it's almost 4 in the morning. I keeping telling myself I'll go to bed earlier, yet I keep getting sucked in to stuff like this...

Navigation

Comments