Description
This issue has a bounty!
Successfully closing this issue by producing a production-ready, mergeable PR can earn you not only the undying love of the IPFS community — it can net you a financial reward. See the current list of bounty issues and their values here.
The need in brief
Add UnisFSv1.5 metadata support per the spec https://github.com/ipfs/specs/blob/master/UNIXFS.md#data-format, which includes: specifying metadata, respecting existing metadata, and displaying metadata.
This aims to support large data import use cases (ex package managers), who need to retain file metadata, particularly last modified time (mtime
), in order to selectively sync only data that has changed. Up until now if you wanted to host a large data set on IPFS, like a package manager's repository, it would be difficult to update - but with file mtime
you can only reimport the changed files, making things much more efficient.
Deliverable
- Implement the new mode & mtime fields and obey the new rules around default modes & mtimes as per the metadata spec.
- Plumb this metadata all the way through from
ipfs add
on one IPFS node toipfs get
on another. - An end-to-end sharness test that validates that this metadata is preserved.
Requirements
- This feature must be interoperable with js-ipfs's implementation of the UnixFSv1.5 spec.
- The behavior of
ipfs add
must not change except when the user has requested that metadata be preserved via the appropriate flags (see the implementation details below). Specifically, the final hash produced byipfs add
must not change. - The final hash of files added with this feature enabled must match the hash produced by javascript.
Guidelines
- Please use the IPFS Go Contributing Guidelines as your north star — adherence to these guidelines are crucial when it comes to awarding a potential bounty!
- Please DO NOT bundle a general code refactor with the completion of this bounty!