Make mount_point argument positional in examples/simple.rs#659
Make mount_point argument positional in examples/simple.rs#659numbleroot wants to merge 3 commits intocberner:masterfrom
mount_point argument positional in examples/simple.rs#659Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e8ad493e37
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| // TODO: make positional like other examples. | ||
| /// Act as a client, and mount FUSE at given path | ||
| #[clap(long, default_value = "")] | ||
| mount_point: String, |
There was a problem hiding this comment.
Preserve
--mount-point compatibility for simple example
Making mount_point positional here removes the --mount-point flag that existing repo tooling still uses, so those invocations now fail argument parsing before mount starts (for example fuser-tests/src/commands/simple.rs:31-37, fuser-tests/src/commands/mount.rs:247, fuser-tests/src/experimental.rs:161, and tests/bsd_pjdfs.sh:21 all pass --mount-point). This commit therefore breaks the current test/scripts workflow unless all callers are updated in lockstep or a compatibility alias is kept.
Useful? React with 👍 / 👎.
…sted scripts and tests accordingly.
Simple change to fix the
TODOstated for CLI argumentmount_pointinexamples/simple.rs: To make the argument positional, as is the case for the other examples. This is achieved simply by removing the#[clap(long, default_value = "")]line right abovemount_point, as fields without attributes define positional arguments by default. And by adjusting the tests that use thesimpleexample.Thanks for building and maintaining this useful crate!