Skip to content

Commit 83b28f4

Browse files
authored
docs: update documentation for 2.5 (#325)
[ci skip]
1 parent 1aa5b8c commit 83b28f4

File tree

116 files changed

+80611
-19
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+80611
-19
lines changed

docs/api/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ uid: latest_api_ref
44
API Reference
55
=============
66

7-
**Version 2.4**
7+
**Version 2.5**
88

99
McMaster.Extensions.CommandLineUtils supports three target frameworks.
1010

docs/docfx.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
2+
"$schema": "https://dotnet.github.io/docfx/schemas/v1.0/schema.json",
23
"metadata": [
34
{
45
"src": [
@@ -23,7 +24,8 @@
2324
"build": {
2425
"content": [
2526
{ "version": "unstable", "files": ["**/*.yml", "**/*.md"], "src": "obj/unstable", "dest": "unstable" },
26-
{ "version": "v2.4", "files": ["**/*.yml", "**/*.md"], "exclude": [ "v2.2/", "v2.3/", "obj/", "**.meta", "README.md", "filterConfig.yml" ] },
27+
{ "version": "v2.5", "files": ["**/*.yml", "**/*.md"], "exclude": [ "v2.2/", "v2.3/", "v2.4/", "obj/", "**.meta", "README.md", "filterConfig.yml" ] },
28+
{ "version": "v2.4", "files": ["**/*.yml", "**/*.md"], "src": "v2.4", "dest": "v2.4" },
2729
{ "version": "v2.3", "files": ["**/*.yml", "**/*.md"], "src": "v2.3", "dest": "v2.3" },
2830
{ "version": "v2.2", "files": ["**/*.yml", "**/*.md"], "src": "v2.2", "dest": "v2.2" }
2931
],

docs/docs/advanced/generic-host.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,17 @@ as well as command line parsing options with this library.
2323

2424
Generic host integration allows you to use the most current DI configuration approach indicated by the aspnet project. The basic approach starts by creating the builder:
2525

26-
[!code-csharp[](../../samples/dependency-injection/generic-host/Program.cs?name=Program&range=26-26)]
26+
[!code-csharp[Program](../../samples/dependency-injection/generic-host/Program.cs?range=26-26)]
2727

2828
Then you can configure your features:
2929

30-
[!code-csharp[](../../samples/dependency-injection/generic-host/Program.cs?name=Program&range=27-34)]
30+
[!code-csharp[Program](../../samples/dependency-injection/generic-host/Program.cs?range=27-34)]
3131

3232
And finally, run your program:
3333

34-
[!code-csharp[](../../samples/dependency-injection/generic-host/Program.cs?name=Program&range=35-35)]
34+
[!code-csharp[Program](../../samples/dependency-injection/generic-host/Program.cs?range=35-35)]
3535

3636
Below is the full source code for the generic host services example. Notice that instance of `IGreeter` will be injected into the `Program` constructor thanks to the dependency injection.
3737

38-
[!code-csharp[](../../samples/dependency-injection/custom/Program.cs?name=Program&highlight=32-32)]
38+
[!code-csharp[Program](../../samples/dependency-injection/custom/Program.cs?highlight=32)]
3939

docs/filterConfig.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
apiRules:
22
- exclude:
3-
uidRegex: ^System\.Object
4-
type: Type
3+
uidRegex: ^System\.Object
4+
type: Type
55
- exclude:
6-
uidRegex: ^System\.Attribute
7-
type: Type
6+
uidRegex: ^System\.Attribute
7+
type: Type
88
- exclude:
9-
uidRegex: ^System\.ComponentModel\.DataAnnotations\.ValidationAttribute
10-
type: Type
9+
uidRegex: ^System\.ComponentModel\.DataAnnotations\.ValidationAttribute
10+
type: Type

docs/generate.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ try {
2424
exec git worktree add $targetDir gh-pages 2>&1 | out-null
2525
}
2626

27-
$docfxVersion = '2.45.0'
27+
$docfxVersion = '2.48.0'
2828
$docfxRoot = "$buildRoot/packages/docfx.console/$docfxVersion"
2929
$docfx = "$docfxRoot/tools/docfx.exe"
3030
if (-not (Test-Path $docfx)) {

docs/toc.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
- name: Documentation
44
href: docs/
55
- name: API Reference
6-
href: api/index.md
6+
href: api/
77
dropdown: true
88
items:
9-
- name: Latest
10-
href: api/index.md
9+
- name: Latest (v2.5)
10+
href: api/
1111
- name: v2.4
12-
href: v2.4/api/
12+
topicHref: /CommandLineUtils/v2.4/api/index.html
1313
- name: v2.3
1414
topicHref: /CommandLineUtils/v2.3/api/index.html
1515
- name: v2.2

docs/v2.4/api/index.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
---
2+
uid: latest_api_ref
3+
---
4+
API Reference
5+
=============
6+
7+
**Version 2.4**
8+
9+
McMaster.Extensions.CommandLineUtils supports three target frameworks.
10+
11+
- .NET Standard 2.0
12+
- .NET Standard 1.6
13+
- .NET Framework 4.5
14+
15+
The API is almost identical between all of the frameworks.
16+
17+
The main entry point for most command line applications is [CommandLineApplication](xref:McMaster.Extensions.CommandLineUtils.CommandLineApplication).
18+
19+
For apps built using attributes, these are the most common attributes used:
20+
21+
- [OptionAttribute](xref:McMaster.Extensions.CommandLineUtils.OptionAttribute)
22+
- [ArgumentAttribute](xref:McMaster.Extensions.CommandLineUtils.ArgumentAttribute)
23+
- [CommandAttribute](xref:McMaster.Extensions.CommandLineUtils.CommandAttribute)
24+
- [SubcommandAttribute](xref:McMaster.Extensions.CommandLineUtils.SubcommandAttribute)
25+
- [HelpOptionAttribute](xref:McMaster.Extensions.CommandLineUtils.HelpOptionAttribute)
26+
27+
Other commonly used types include
28+
29+
- [DotNetExe](xref:McMaster.Extensions.CommandLineUtils.DotNetExe)
30+
- [Prompt](xref:McMaster.Extensions.CommandLineUtils.Prompt)
31+
- [ArgumentEscaper](xref:McMaster.Extensions.CommandLineUtils.ArgumentEscaper)
32+
- [IConsole](xref:McMaster.Extensions.CommandLineUtils.IConsole)

docs/v2.4/toc.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
- name: API Reference
2+
href: api/index.md

0 commit comments

Comments
 (0)