Skip to content

Commit 0b17e34

Browse files
authored
Add links to the docs to the README (#396)
* Add links to docs to the README * Light article revisions
1 parent 2b352c0 commit 0b17e34

File tree

4 files changed

+29
-12
lines changed

4 files changed

+29
-12
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
/Packages
44
/*.xcodeproj
55
.swiftpm
6+
.vscode
67
.*.sw?

README.md

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,10 +66,18 @@ OPTIONS:
6666
-h, --help Show help for this command.
6767
```
6868

69-
For more information and documentation about all supported options,
70-
see the library's documentation in Xcode.
69+
## Documentation
7170

72-
## Examples
71+
For guides, articles, and API documentation see the
72+
[library's documentation on the Web][docs] or in Xcode.
73+
74+
- [ArgumentParser documentation][docs]
75+
- [Getting Started with ArgumentParser](https://apple.github.io/swift-argument-parser/documentation/argumentparser/gettingstarted)
76+
- [`ParsableCommand` documentation](https://apple.github.io/swift-argument-parser/documentation/argumentparser/parsablecommand)
77+
78+
[docs]: https://apple.github.io/swift-argument-parser/documentation/argumentparser/
79+
80+
#### Examples
7381

7482
This repository includes a few examples of using the library:
7583

@@ -79,8 +87,8 @@ This repository includes a few examples of using the library:
7987

8088
You can also see examples of `ArgumentParser` adoption among Swift project tools:
8189

82-
- [`indexstore-db`](https://github.com/apple/indexstore-db/pull/72) is a simple utility with two commands.
83-
- [`swift-format`](https://github.com/apple/swift-format/pull/154) uses some advanced features, like custom option values and hidden flags.
90+
- [`swift-format`](https://github.com/apple/swift-format/) uses some advanced features, like custom option values and hidden flags.
91+
- [`swift-package-manager`](https://github.com/apple/swift-package-manager/) includes a deep command hierarchy and extensive use of option groups.
8492

8593
## Project Status
8694

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,19 @@
11
# Experimental Features
2-
Learn about what experimental features ArgumentParser has.
2+
3+
Learn about ArgumentParser's experimental features.
34

45
## Overview
5-
ArgumentParser has some built-in experimental features and they are available with the prefix `--experimental`. If you have any feedback on the experimental features, please open an issue.
66

7-
## List of experimental features
8-
### Experimental Flags
7+
Command-line programs built using `ArgumentParser` may include some built-in experimental features, available with the prefix `--experimental`. These features should not be considered stable while still prefixed, as future releases may change their behavior or remove them.
8+
9+
If you have any feedback on experimental features, please [open a GitHub issue][issue].
10+
11+
## List of Experimental Features
12+
913
| Name | Description | related PRs | Version |
1014
| ------------- | ------------- | ------------- | ------------- |
11-
| `--experimental-dump-help` | Dumps command/argument/help information as JSON | [#310](https://github.com/apple/swift-argument-parser/pull/310) [#335](https://github.com/apple/swift-argument-parser/pull/335) | 0.5.0 or newer |
15+
| `--experimental-dump-help` | Dumps command/argument/help information as JSON | [#310][] [#335][] | 0.5.0 or newer |
16+
17+
[#310]: https://github.com/apple/swift-argument-parser/pull/310
18+
[#335]: https://github.com/apple/swift-argument-parser/pull/335
19+
[issue]: https://github.com/apple/swift-argument-parser/issues/new/choose

Sources/ArgumentParser/Documentation.docc/Articles/ManualParsing.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Manual Parsing and Testing
22

3-
Provide your own array of command-line inputs and work with parsed results by calling alternatives to `main()`.
3+
Provide your own array of command-line inputs or work directly with parsed command-line arguments.
44

55
## Overview
66

7-
For most programs, calling the static `main()` method on the root command type is all that's necessary. That single call parses the command-line arguments to find the correct command from your tree of nested subcommands, instantiates and validates the result, and executes the chosen command. For more control, however, you can perform each of those steps manually.
7+
For most programs, denoting the root command type as `@main` is all that's necessary. As the program's entry point, that type parses the command-line arguments to find the correct command from your tree of nested subcommands, instantiates and validates the result, and executes the chosen command. For more control, however, you can perform each of those steps manually.
88

99
## Parsing Arguments
1010

0 commit comments

Comments
 (0)