shir0kamii
ee3d12ec56
fix(derive): Abort on non-unit variant
2022-03-30 03:49:14 +02:00
Matt Fellenz
17193bd074
docs(derive): Builder/Derive interop reference ( #3515 )
...
Fixes #3500
2022-03-07 14:43:51 -06:00
Pavan Kumar Sunkara
8a9403a1df
Fixes #3464
2022-03-05 14:25:12 +00:00
Lucas Kent
0fe8ca7d3c
docs(derive): Shift structure around lang->builder
...
Before, we had the focus on attributes and how they were impacted by
various features. Now we separate out language items and put both magic
and raw attributes under the type of attribute (command, arg, etc)
2022-03-02 16:14:51 -06:00
Moritz Mœller
22efb36983
Fixed broken Command Attributes link
2022-02-24 13:39:53 +01:00
Ed Page
a7b7d43582
docs(derive): Call out 'Command' relationship
2022-02-22 18:09:47 -06:00
Ed Page
7e51f7c03d
docs(derive): Call out different subcommand arg syntaxes
2022-02-22 08:32:18 -06:00
Ed Page
517b8e4233
docs(derive): Clarify the break down
2022-02-22 08:31:02 -06:00
Ed Page
e8010e79a9
refactor: Update app variables to cmd
2022-02-14 15:55:56 -06:00
Ed Page
c4144d7d6c
docs: Update App references to Command
2022-02-14 15:33:49 -06:00
Ed Page
97e36451cf
docs: Update stale references to AppSettings
2022-02-11 15:58:12 -06:00
Ed Page
5290f82133
feat: Override DeriveDisplayOrder behavior with App::next_display_order
...
For the derive API, you can only call `next_display_order` when dealing
with a flatten. Until we offer app attributes on arguments, the user can workaround with
this no-op flattens.
This is a part of #1807
2022-02-07 19:19:11 -06:00
Ed Page
c00f71ec4a
feat: Add App::next_help_heading
...
This clarifies the intent and prepares for other functions doing the
same, like `next_display_order`. This will then open us to name
`subcommand_help_heading` and `display_order` similar.
The deprecation is waiting on 3.1.
This is part of #1807 and #1553 .
2022-02-07 19:19:01 -06:00
Ed Page
d318752cac
docs(derive): Expand on parse attribute
2022-02-02 10:37:47 -06:00
mikehoyle
50b3d2966e
Correct README syntax for bool flag ( #3346 )
...
The proper syntax for the attribute is "parse" not "parser".
2022-01-26 08:41:09 -06:00
omjadas
86c83d296f
feat: Add default_value_os_t ( #3333 )
...
The order of suffixes allows us to preserve the original builder function name.
This is a part of #2813
2022-01-24 15:32:21 -06:00
Ed Page
ddad3a7923
docs(derive): Clarify from_flag's interactions
2022-01-20 09:55:13 -06:00
Ed Page
63a36673e1
docs(derive): Link ref to tutorial / examples
2022-01-11 14:27:39 -06:00
Ed Page
4b51b8e253
docs(examples): Steer people to know about about vs long_about
...
`#[clap(about)]` only overrides `about`. If the doc comment also sets
`long_about`, it won't be overridden. This change is to help raise
visibility of reseting `long_about` in these cases.
2022-01-10 18:47:24 -06:00
Ed Page
64d16bbc03
docs(derive): Clarify which Cargo.toml field is read
2022-01-10 18:32:32 -06:00
Ed Page
c5ace9aaa6
docs(derive): Clarify what can be used with flatten
2022-01-10 08:03:59 -06:00
Ed Page
fe56bb112d
doc(derive): Clarify need to do long_about = None
2022-01-10 07:25:54 -06:00
Ed Page
b0cb2057ea
docs(derive): Include name magic attribute
...
Inspired by #3242l
2022-01-03 06:33:53 -06:00
Ed Page
a37f2908c8
docs(derive): Looks like optional isnt supported
...
According to #2587
2021-12-23 10:29:34 -06:00
Ed Page
653617d0fd
docs(derive): Add flatten/subcommand for variants
2021-12-23 10:27:07 -06:00
Ed Page
8924dd7a1e
feat(derive): Don't require Display
for default ArgEnum
...
While I'm unsure how much type specialization we should do, we
intentionally have the `arg_enum` attribute for doing special behavior
based on it, so let's take advantage of it.
Fixes #3185
2021-12-16 09:11:32 -06:00
Ed Page
03cb509d6c
refactor(examples): Change naming style
...
This is to make room for a reasonable looking cargo plugin example.
I got lazy and didn't update the tutorials.
2021-12-15 11:12:18 -06:00
p4tr1ck
f3afcee855
examples: Fix typo
2021-12-13 22:34:08 +08:00
Ed Page
7731ca2d21
docs(derive): Show how to override special types
...
Fixes #3107
2021-12-09 09:32:33 -06:00
Ed Page
76828fada8
docs: Guide people to missing_docs lint
2021-12-07 21:22:12 -06:00
Ed Page
6da9277522
docs(derive): Note Option Vec behavior
2021-12-07 17:45:57 -06:00
Ed Page
27acb95cd9
docs: Add Derive API reference
...
I took more inspiration for organization from `serde.rs` than `docs.rs/structopt`.
2021-12-01 21:23:06 -06:00