summaryrefslogtreecommitdiffstats
path: root/vendor/clap/examples/README.md
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:02:58 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:02:58 +0000
commit698f8c2f01ea549d77d7dc3338a12e04c11057b9 (patch)
tree173a775858bd501c378080a10dca74132f05bc50 /vendor/clap/examples/README.md
parentInitial commit. (diff)
downloadrustc-698f8c2f01ea549d77d7dc3338a12e04c11057b9.tar.xz
rustc-698f8c2f01ea549d77d7dc3338a12e04c11057b9.zip
Adding upstream version 1.64.0+dfsg1.upstream/1.64.0+dfsg1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'vendor/clap/examples/README.md')
-rw-r--r--vendor/clap/examples/README.md40
1 files changed, 40 insertions, 0 deletions
diff --git a/vendor/clap/examples/README.md b/vendor/clap/examples/README.md
new file mode 100644
index 000000000..2034ab80e
--- /dev/null
+++ b/vendor/clap/examples/README.md
@@ -0,0 +1,40 @@
+# Examples
+
+- Basic demo: [derive](demo.md)
+- Typed arguments: [derive](typed-derive.md)
+ - Topics:
+ - Custom `parse()`
+- Custom cargo command: [builder](cargo-example.md), [derive](cargo-example-derive.md)
+ - Topics:
+ - Subcommands
+ - Cargo plugins
+- git-like interface: [builder](git.md), [derive](git-derive.md)
+ - Topics:
+ - Subcommands
+ - External subcommands
+ - Optional subcommands
+ - Default subcommands
+- pacman-like interface: [builder](pacman.md)
+ - Topics:
+ - Flag subcommands
+ - Conflicting arguments
+- Escaped positionals with `--`: [builder](escaped-positional.md), [derive](escaped-positional-derive.md)
+- Multi-call
+ - busybox: [builder](multicall-busybox.md)
+ - Topics:
+ - Subcommands
+ - hostname: [builder](multicall-hostname.md)
+ - Topics:
+ - Subcommands
+- repl: [builder](repl.rs)
+ - Topics:
+ - Read-Eval-Print Loops / Custom command lines
+
+## Contributing
+
+New examples:
+- Building: They must be added to [Cargo.toml](../Cargo.toml) with the appropriate `required-features`.
+- Testing: Ensure there is a markdown file with [trycmd](https://docs.rs/trycmd) syntax
+- Link the `.md` file from here
+
+See also the general [CONTRIBUTING](../CONTRIBUTING.md).