Windows people: please help check idea for a new Mercurial repository layout

Adrian Buehlmann adrian at cadifra.com
Tue Jun 17 02:56:57 CDT 2008


On 17.06.2008 08:03, Peter Arrenbrecht wrote:
> Judging by your reaction I'm not sure I got my point across clearly.
> Let's say we have repo U on Unix, containing a file called aux. You
> then *can* do

Yes, I got your point. Thanks ("No, thanks", actually :-).

>   [Windows]
>   hg clone http://nix.example.com/hg/U W
>   warning: dropping history for the/path/aux (incompatible file name)
>   updating working copy
> 
> If aux is still active (not deleted in the current revision), you would also get
> 
>   warning: not restoring the/path/aux (history missing)
> 
> This will create a repo W which lacks aux.i/.d and the clone operation
> issues a suitable warning. What you now *cannot* do is
> 
>   [some other machine]
>   hg clone http://win.example.com/hg/W X
> 
> But you *can* do
> 
>   [Windows]
>   hg clone W X
> 
> This is similar to your original proposition to simply abort on
> encountering a reserved name instead of hanging. But now we don't
> abort. Instead we warn and drop the incompatible files. Granted, this
> leaves us with an incomplete repo. But it means Windows people can
> still get it and work on the compatible parts (which are all of them
> if aux has meanwhile been renamed or deleted). They just cannot be a
> full-clone source over the wire (it could be supported, but I don't
> think it should). All this without the need for a repo format change.

And what about if the offending name in the repo is a rename
(x -> aux -> y) and you need to do a merge across that rename
on Windows?

With a repo that actually does contain the *complete* history,
we can be sure the we can do merges across renames (or whatever
other current or future feature that may be).

Also having the full history available even on Windows seems
like a natural feature of a repo, isn't it? (you can see
what happened exactly, even on a crippled system like Windows).

And do we want to support those broken repos we start leaving behind
on Windows for all the coming releases of Mercurial? And who does
the regression tests on these broken repos?

I for one say *no thanks* to repos that don't hg verify.

Folks, it's nice to list all these dirty tricks to safe our buts
with regards to not have to introduce a new repo format.
But at some point, things start getting silly, really.

We can go on and on with this "reserved names" discussion, jump
forward and backwards to the "long paths" at the discretion of
the poster at hand who uses it as an argument to demonstrate how
easy it is to do hack X or Y.

Can we please stop advocating broken repositories on Windows
if we have a stupid simple, easy to implement and easy to mark
repository encoding?

And it would be interesting to know why people insist on sticking
to that current "compatible" format on Windows if we either

(1) don't have the tools to move these "compatible" repos around
    (Explorer/Winzip/Samba can't deal with \\?\C:\aux.i files)

or

(2) the repo is incomplete and does not hg verify (Arrenbrecht)?


More information about the Mercurial mailing list