Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fuse_iso example does not work #10

Open
inferiorhumanorgans opened this issue Aug 26, 2023 · 1 comment
Open

fuse_iso example does not work #10

inferiorhumanorgans opened this issue Aug 26, 2023 · 1 comment

Comments

@inferiorhumanorgans
Copy link

inferiorhumanorgans commented Aug 26, 2023

There are a few issues that prevent it from working. I've updated it so that the basics work from a shell (e.g. cd, ls, cat). I've moved my efforts over to sourcehut for a variety of reasons so I can't open a PR directly.

The source is available here:

https://git.sr.ht/~az1/iso9660-rs/tree/fuse-example/item/examples/iso_fuse.rs

And here's a patchset:

fuse-example.patch

@inferiorhumanorgans
Copy link
Author

inferiorhumanorgans commented Aug 26, 2023

Here's the patch for the other two examples.

Subject: [PATCH] Bring the other two examples in line with iso_fuse

Hopefully this is all a bit more idiomatic.

- Group related imports into single blocks
- Use clap for argument parsing
- Use anyhow for error handling
- main returns Result<(), anyhow::Error> for human readable error messages
- Use anyhow::bail instead of exit or panic
- Use PathBuf instead of String for paths, the next logical step is to update the iso9660 API to stop
  taking path strings
- Use string interpolation in format strings
- Use std::iter::repeat for string repetition

https://git.sr.ht/~az1/iso9660-rs/commit/b798178dc2f26c65a6aaaa151206e13c996e213d.patch

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

No branches or pull requests

1 participant