Skip to content

Commit

Permalink
[dotnet] Generate API documentation (#11968)
Browse files Browse the repository at this point in the history
Co-authored-by: Diego Molina <diemol@users.noreply.github.com>
  • Loading branch information
nvborisenko and diemol authored May 5, 2023
1 parent 8efae1b commit 55283eb
Show file tree
Hide file tree
Showing 11 changed files with 96 additions and 80 deletions.
9 changes: 9 additions & 0 deletions dotnet/docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
###############
# folder #
###############
/**/DROP/
/**/TEMP/
/**/packages/
/**/bin/
/**/obj/
_site
5 changes: 5 additions & 0 deletions dotnet/docs/api/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
###############
# temp file #
###############
*.yml
.manifest
2 changes: 2 additions & 0 deletions dotnet/docs/api/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# PLACEHOLDER
TODO: Add .NET projects to the *src* folder and run `docfx` to generate **REAL** *API Documentation*!
1 change: 1 addition & 0 deletions dotnet/docs/articles/intro.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Add your introductions here!
2 changes: 2 additions & 0 deletions dotnet/docs/articles/toc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- name: Introduction
href: intro.md
12 changes: 0 additions & 12 deletions dotnet/docs/build.desc

This file was deleted.

58 changes: 58 additions & 0 deletions dotnet/docs/docfx.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{
"metadata": [
{
"src": [
{
"files": [
"src/webdriver/WebDriver.csproj",
"bin/**/*.dll"
],
"src": "../"
}
],
"dest": "api",
"includePrivateMembers": false,
"disableGitFeatures": false,
"disableDefaultFilter": false,
"noRestore": false,
"namespaceLayout": "flattened",
"memberLayout": "samePage",
"allowCompilationErrors": false
}
],
"build": {
"content": [
{
"files": [
"api/**.yml",
"api/index.md"
]
},
{
"files": [
"articles/**.md",
"articles/**/toc.yml",
"toc.yml",
"*.md"
]
}
],
"resource": [
{
"files": [
"images/**"
]
}
],
"dest": "../../build/docs/api/dotnet",
"globalMetadataFiles": [],
"fileMetadataFiles": [],
"template": [
"default",
"modern"
],
"postProcessors": [],
"keepFileLink": false,
"disableGitFeatures": false
}
}
68 changes: 0 additions & 68 deletions dotnet/docs/docs.shfbproj

This file was deleted.

4 changes: 4 additions & 0 deletions dotnet/docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# This is the **HOMEPAGE**.
Refer to [Markdown](http://daringfireball.net/projects/markdown/) for how to write markdown files.
## Quick Start Notes:
1. Add images to the *images* folder if the file is referencing an image.
5 changes: 5 additions & 0 deletions dotnet/docs/toc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
- name: Articles
href: articles/
- name: Api Documentation
href: api/
homepage: api/index.md
10 changes: 10 additions & 0 deletions generate_api_docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ rb)
bazel run //rb:docs || exit
docs="$(bazel cquery --output=files //rb:docs 2> /dev/null).runfiles/selenium/docs/api/rb"
;;
dotnet)
# dotnet sdk should be installed
# bazel should be installed
dotnet tool update -g docfx
docfx dotnet/docs/docfx.json
;;
*)
echo "Selenium API docs generation"
echo "ERROR: unknown parameter \"$API_DOCS_LANGUAGE\""
Expand Down Expand Up @@ -44,6 +50,10 @@ rb)
rm -rf docs/api/rb
mv $docs docs/api/rb
;;
dotnet)
rm -rf docs/api/dotnet
mv build/docs/api/dotnet docs/api/dotnet
;;
*)
echo "ERROR: unknown parameter \"$API_DOCS_LANGUAGE\""
exit 1
Expand Down

0 comments on commit 55283eb

Please sign in to comment.