Skip to content

Generate and parse image timestamps#155

Draft
astarivi wants to merge 3 commits into
antangelo:mainfrom
astarivi:time
Draft

Generate and parse image timestamps#155
astarivi wants to merge 3 commits into
antangelo:mainfrom
astarivi:time

Conversation

@astarivi

@astarivi astarivi commented Jul 24, 2025

Copy link
Copy Markdown
Contributor

Addresses #37 by introducing an implementation-agnostic FileTime struct at the core module, allowing downstream to implement their own time gen and parsing mechanisms.

To implement this new time structure into the image write logic, a new function create_xdvdfs_image_with_filetime has been created, which takes the FileTime struct as an argument. create_xdvdfs_image is still available, and will default to a 0 timestamp value.

Implementation details:

xdvdfs-cli

  • Uses chrono crate to generate and parse dates.
  • Adds two new flags timestamp (-t) and timestamp_now (-T) to pack and compress sub-commands. These default to a 0 timestamp value if no flag is given (see Make the pack command produce a predictable image file from the same content source. #101)
  • info sub-command will now print the parsed (RFC 3339), and the Unix equivalent of the image timestamp.
  • exiso_compat is excluded from this implementation.
  • build_image is excluded from this implementation (timestamp should be a part of the spec file?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant