Skip to content

Tracking Issue: High-level API filesystem usability #995

@RaitoBezarius

Description

@RaitoBezarius

This is a follow-up of #747, I have been playing around with it and I have a bit of wishlist (of course, would love to contribute directly some of them), but want to discuss with you.

  1. FileSystemResult doesn't compose well with uefi::Result, maybe we should have a 4th variant UEFIError or something or transform easily any FileSystemResult into a uefi::Result, I don't really know what is the best but what I am seeing is that we need more powerful and user-friendly errors when writing FS code that mixes UEFI code and FS code.
  2. Constructing paths: there's no join operations at the moment I believe.
  3. Constructing OS paths: while we live in UEFI land, and we use CStr16 everywhere, sometimes, we would like to write UNIX or Windows paths in some file that we are preparing for boot, e.g. in lanzaboote, we would like to assemble a CPIO archive, the paths are therefore UTF-8 UNIX paths. For this, I wish I had std::path::Path, but I don't :-). It would be interesting to see if we can find an alloc solution for that (maybe it's a Rust upstream issue).
  4. is_ascii is a missing on CStr16 I think (same for is_utf8), it would be useful to have it for many FS work (where I want to exclude any weird filenames).
  5. Weird impedence mismatch between fs.open_volume and opening a filesystem with SimpleFilesystem, I can never get a Directory this way, how is it envisioned to get a handle on the root directory in the high level API?

I think this is all I can think of right now. (feel free to rename the issues or whatever.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions