| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| | |
|
| |
|
|
|
|
| |
The code for printing usage became quite verbose after writegate.
Writing usage to a file like stdout and stderr is very common, so this
wrapper provides a default, buffered way to report to a file.
|
| |
|
|
|
|
| |
The code for printing help became quite verbose after writegate. Writing
help to a file like stdout and stderr is very common, so this wrapper
provides a default, buffered way to report to a file.
|
| |
|
|
|
|
| |
The code for reporting errors became quite verbose after writegate.
Reporting to stderr is very common, so this wrapper provides a default,
buffered way to report to a file.
|
| | |
|
| |
|
|
| |
Fixes #149
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
For `Values.one` positionals will be of type `?T`
For `Values.many` positonals will be of type `[]const T`
|
| |
|
|
| |
This is my new preferred style of programming Zig :)
|
| |
|
|
|
|
|
|
| |
This option makes `clap.parse` and `clap.parseEx` stop parsing after
encountering a certain positional index. Setting
`terminating_positional` to 0 will make them stop parsing after the 0th
positional has been added to `positionals` (aka after parsing 1
positional)
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
| |
A complete solution would be to count grapheme clusters, but that would
require adding a dependency on something like zg.
Counting codepoints will ensure that typical non-ASCII text is
supported, but you can still throw it off with more complex Unicode
constructions, which might not be so useful in help text.
Fixes #75
|
| | |
|
| |
|
|
|
|
| |
See https://github.com/ziglang/zig/pull/19847
Compatibility with Zig 0.13.0 remains unchanged
|
| |
|
|
| |
related #122
|
| | |
|
| | |
|
| |
|
|
| |
fixes #111
|
| |
|
|
| |
fixes #84
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Breaking change: parseEx now counts the number of occurrences of flag
parameters (those with takes_value == .none) and returns the count as a
u8. Users of the library will need to change
if (arg_result.my_flag)
to
if (arg_result.my_flag != 0)
|
| |
|
|
| |
update to follow latest for loop syntax
|
| | |
|
| |
|
|
| |
Rename `builtin.Struct.field_type` to `builtin.Struct.type`.
|
| |
|
|
| |
toOwnedSlice() now returns an error union
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
Syncs with latest zig master version 0.10.0-dev.4117+54854e2ab
|
| |
|
|
|
| |
Also enable test suit for both stage 1 and stage 2, to ensure we don't
break things for people who haven't switched yet.
|
| |
|
|
| |
fixes #79
|
| | |
|
| |
|
|
| |
fixes \#28
|
| | |
|
| | |
|
| |
|
|
|
|
| |
This new parser stops when it hits something that looks like a new
parameter. This is the precurser to parsing multiple parameters in a
single function.
|
| |
|
|
| |
fixes #72
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes
- `.flag`, `.option`, `.options` and `.positionals` are now just fields
you access on the result of `parse` and `parseEx`.
- `clap.ComptimeClap` has been removed.
- `clap.StreamingClap` is now called `clap.streaming.Clap`
- `parse` and `parseEx` now takes a `value_parsers` argument that
provides the parsers to parse values.
- Remove `helpEx`, `helpFull`, `usageEx` and `usageFull`. They now just
expect `Id` to have methods for getting the description and value
texts.
|
| |
|
|
| |
This reverts commit cfaac64c404fb1c2e892880410aa3b7dd881ea58.
|
| |
|
|
|
|
|
|
|
| |
This changes
- `.flag`, `.option`, `.options` and `.positionals` are now just fields
you access.
- Move the current `clap.parse` and friends into `clap.untyped.parse`
- This is in preperation for `clap.typed.parse`
|
| |
|
|
|
|
|
|
|
| |
They now follow the interface provided by the standard library. This now
means that we no longer needs `args.OsIterator` as that the one from
`std` can now be used directly.
Also remove `args.ShellIterator` as a simular iterator exists in `std`
called `ArgIteratorGeneral`.
|
| |
|
|
|
|
| |
The current Zig print API is quite good at slowing down compilation and
producing binary bloat. This commit makes an attempt to avoid using it
when not nessesary.
|