Commit graph

4860 commits

Author SHA1 Message Date
Ed Page
ea7699c11f chore: Release 2022-01-24 15:34:27 -06:00
Ed Page
d09188a7ce docs: Update changelog 2022-01-24 15:33:12 -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
e5b06c3061 chore: Release 2022-01-24 10:54:50 -06:00
Ed Page
ac43b7baee docs: Update changelog 2022-01-24 10:54:04 -06:00
Ed Page
af5502461c
Merge pull request #3334 from epage/source
fix(parser): Track the most explicit value source
2022-01-24 10:51:25 -06:00
Ed Page
c6664afe9d fix(parser): Track the most explicit value source
We were only tracking the last value source (default, env, cli, etc).
This works for args because they only come from one source.  Groups
however can come from multiple sources and this was making us treat a
group with a default value as being completely from defaults despite
some values maybe being from the commandline.

We now track the highest precedence value for a group.

Fixes #3330
2022-01-24 10:34:41 -06:00
Ed Page
afd0342a9b docs(readme): discuss API trade offs
Fixes #3329
2022-01-24 08:29:02 -06:00
Ed Page
43673a1bd1 docs(error): Update reported failure code
Fixes #3332
2022-01-24 08:11:18 -06:00
Ed Page
a7f33efd80 docs(faq): Note clap-serde 2022-01-21 09:49:01 -06:00
Ed Page
0dd169be52
Merge pull request #3328 from epage/panic
Clarify some panics
2022-01-21 08:51:16 -06:00
Ed Page
afb2a3dd05 docs(complete): Clarify some panic conditions 2022-01-21 08:29:38 -06:00
Ed Page
b488aab46c fix: Clarify some unwraps as expects
This was inspiredby #3322
2022-01-21 08:27:18 -06:00
Ed Page
ddad3a7923 docs(derive): Clarify from_flag's interactions 2022-01-20 09:55:13 -06:00
Ed Page
1d6d293ccd
Merge pull request #3314 from epage/docs
docs: More cross-linking to make derive docs discoverable
2022-01-18 19:53:07 -06:00
Ed Page
4c2d65e290 docs(derive): Have crate link out to specific docs 2022-01-18 19:41:29 -06:00
Ed Page
3468325b8d docs: Describe the example we show
This also provides us another opportunity to link to the docs.
2022-01-18 19:38:53 -06:00
Ed Page
5877f884f1 chore: Release 2022-01-18 14:59:58 -06:00
Ed Page
8cfa3567ef docs: Update changelog 2022-01-18 14:59:48 -06:00
Ed Page
c6b5f640a4
Merge pull request #3311 from epage/fix
fix: Don't panic when propagating
2022-01-18 14:58:34 -06:00
Ed Page
38e6952d46 fix: Don't panic when propagating
I thought I was adding a test in #3305.  Maybe I considered the
clap_complete changes sufficient for this.  Doing more `debug_assert`s
would be good also.

Unsetting `PropagateVersion` helps in some cases but we need to unset it
globally to override the global propagation.

Fixes #3310
2022-01-18 14:38:58 -06:00
Ed Page
4b60440d91 docs: Note case in #3309 2022-01-18 10:30:51 -06:00
Ed Page
bd1bf66279 chore: Release 2022-01-17 20:34:09 -06:00
Ed Page
4e51f9b0ef docs: Update changelog 2022-01-17 20:33:52 -06:00
Ed Page
784d249a4e
Merge pull request #3306 from sunshowers/sub
implement App::find_subcommand_mut
2022-01-17 20:30:07 -06:00
Rain
236ec973d9 feat: Implement App::find_subcommand_mut
Similar to `App::find_subcommand`, except it returns a mutable reference
to the subcommand.
2022-01-17 12:31:41 -08:00
Ed Page
ccbbba8908 chore: Release 2022-01-17 09:37:45 -06:00
Ed Page
6817a9cab2 docs: Update changelog 2022-01-17 09:37:22 -06:00
Ed Page
ffe6bff8ac
Merge pull request #3305 from epage/help
fix(help): Always respect DisableColoredHelp
2022-01-17 09:35:18 -06:00
Ed Page
4a43b51a42 fix(complete): Handle help completions
The main motivation was to reduce special cases by putting all of the
logic in one place.
2022-01-17 09:23:04 -06:00
Ed Page
e962ad8ce6 fix(help): Always respect DisableColoredHelp
We might be able to handle version/help before propagation but I didn't
want to hold up this fix for that to happen and increase the risk
associated with this fix.

Fixes #3298
2022-01-17 09:14:07 -06:00
Ed Page
807ddbbb70 refactor: Build help subcommand separately 2022-01-17 08:36:37 -06:00
Ed Page
729f4e7e82 refactor: Make subcommand propagation reusable 2022-01-17 08:33:07 -06:00
Ed Page
3620cad5fa
Merge pull request #3297 from kornelski/track_asserts
Track caller on methods using assertions
2022-01-17 08:00:42 -06:00
Ed Page
d52b326c7b
Merge pull request #3302 from whfuyn/master
docs: Fix mismatched `
2022-01-17 07:43:06 -06:00
Zhishi
fbbd70ccc9 docs: Fix mismatched ` 2022-01-17 19:06:22 +08:00
Kornel
0121690f9c Track caller on methods using assertions 2022-01-16 12:45:25 +00:00
Ed Page
7b7c76e3d0 chore: Release 2022-01-15 18:51:41 -06:00
Ed Page
1c89abaa5b docs: Update changelog 2022-01-15 18:51:23 -06:00
Ed Page
277075d8e2
Merge pull request #3295 from clifton/zsh-about-unescaped
fix: unescaped chars appearing in zsh completion script
2022-01-15 18:50:15 -06:00
Clifton King
658b7a0841 fix(complete): Fix unescaped single quotes in zsh
help strings for subcomand args did not escape single quotes
2022-01-15 14:33:11 -06:00
Ed Page
d178de7cf8 docs(generate): Fix another contributing link 2022-01-13 09:26:11 -06:00
Ed Page
7c3b38f9a6
Merge pull request #3292 from rndhouse/fix_contributing_url
Fix broken CONTRIBUTING.md URL.
2022-01-13 09:25:16 -06:00
rndhouse
85cac43672
Fix broken CONTRIBUTING.md URL. 2022-01-13 15:14:08 +00:00
Ed Page
3d8ce3f426 chore: Release 2022-01-12 11:12:42 -06:00
Ed Page
0439dc221f docs: Update changelogs 2022-01-12 11:11:53 -06:00
Ed Page
b200a869b4
Merge pull request #3288 from epage/assert
fix: Run more parse asserts during build
2022-01-12 11:09:16 -06:00
Ed Page
37f47dd260 docs: Add completion changelogs 2022-01-12 11:04:57 -06:00
Ed Page
b98e8ec24f docs(derive): Args doesn't derive IntoApp
Fixes #3284
2022-01-12 10:58:35 -06:00
Ed Page
de275e7cf9 fix: Run more parse asserts during build
This will help prevent issues from being deployed to users like in #3281

I do not consider this a breaking change because any normal operation
will assert anyways.
2022-01-12 10:55:55 -06:00