[RFC] sha1 of fileid naming for knit files
John Arbash Meinel
john at arbash-meinel.com
Tue Oct 31 15:49:42 GMT 2006
Robert Collins wrote:
> To help out a user trying bzr-svn [which creates loong file ids because
> it needs a mapping back into svn], I have whipped up this plugin -
> http://bazaar.launchpad.net/~lifeless/+junk/sha1repo
>
> Drop it in ~/.bazaar/plugins/sha1repo and you get a new format
> 'knitsha1' which can be addressed via the command line.
>
> This format is essentially a knitformat1 repository with the text store
> changed to use a different algorithm for determining the on disk names.
>
> It sha1's the fileid to get the 40byte hex digest and uses that for the
> filename.
>
> I'm wondering what people think of this as the escaping format to fix
> our problems with respect to apache etc.
>
> -Rob
I think the idea is interesting, and it certainly gives us a way to
restrict ourselves to "safe" characters.
However, it is kind of nice to have the back reference. So if it says
"failed to do X on file foobar-2uaothnthauo.knit" you have an idea what
file is involved. It isn't a perfect mapping, but there is some
information there, which has meaning.
Also, our Knit files don't contain the revision-id of the file they are
versioning. So there is *no* way to build that back reference, other
than trying to extract the content from .knit, and try to match it up.
So I think it at least needs a content change to put some sort of
back-reference.
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20061031/64475479/attachment.pgp
More information about the bazaar
mailing list