Quoting Tamás Gulácsi (2019-06-13 02:29:16)
> Either you can duplicate the file by duplicating a file blob with
> different fileName
This was more or less my intent, but my question was more about how to
avoid formatting the "spine" of the filesystem in such a way that I get
a separate copy of all the file and directory blobs (but not the parts)
if pk put goes over it again by itself, rather than with my own tool.
In particular, at least these things can make two semantically identical
json blobs have different blobrefs:
* Differing whitespace/indentation
* Differing order of object fields
The output from perkeep looks like it was formatted using an
"encoding/json".Encoder configured with .SetIndent("", " ").
If I declare structs with fields declared in the same order as they
appear in the schema blobs, will that and the .SetIndent call be
sufficient to ensure that equivalent blobs have the same hash? (are
these structs declared publicly somewhere? I feel like they should be
but am having trouble finding them in the API docs).
-Ian
--
You received this message because you are subscribed to the Google Groups
"Perkeep" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/perkeep/156044768734.804.16348507711729033114%40localhost.localdomain.
For more options, visit https://groups.google.com/d/optout.