google / google/argh

[Question] `positional` argument with at least one value mandatory

Open
#13 6 comments 1 reaction 0 assignees View on GitHub
Dominant language
Rust
Stars
2k
Forks
102
PR merge metrics
No merged PRs in 30d

Description

Is there a way to specify that a positional arg need at least one value?

```rust
#[derive(FromArgs)]
/// MyCMD
struct Opt {
#[argh(positional)]
/// script files to run
test_file: Vec,
}
```
gives me:
```
Usage: mycmd.exe []
```
Which suggests the tool can work without any input when it needs at least one.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.