Added docs
This commit is contained in:
66
.gitea/workflows/docs-build.yml
Normal file
66
.gitea/workflows/docs-build.yml
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
name: Documentation Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- 'main'
|
||||||
|
|
||||||
|
env:
|
||||||
|
TZ: 'Europe/Berlin'
|
||||||
|
LANG: 'de'
|
||||||
|
CONFIGURATION: 'Release'
|
||||||
|
GITEA_SERVER_URL: ${{ gitea.server_url }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-test-deploy:
|
||||||
|
runs-on: server-runner
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
shell: bash
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository code
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Setup dotnet
|
||||||
|
uses: actions/setup-dotnet@v5
|
||||||
|
with:
|
||||||
|
dotnet-version: 10.x
|
||||||
|
cache: false
|
||||||
|
|
||||||
|
- name: Restore dependencies
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet restore -v q
|
||||||
|
echo "CI_SERVER_HOST=${GITEA_SERVER_URL#https://}" >> "$GITEA_ENV"
|
||||||
|
|
||||||
|
- name: Setup tools
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet tool install dotnet-reportgenerator-globaltool --tool-path /dotnet-tools
|
||||||
|
dotnet tool install docfx --tool-path /dotnet-tools
|
||||||
|
|
||||||
|
- name: Build solution
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
shopt -s globstar
|
||||||
|
mkdir /artifacts
|
||||||
|
dotnet build -c ${CONFIGURATION} --no-restore --nologo
|
||||||
|
mv ./**/*.nupkg /artifacts/ || true
|
||||||
|
mv ./**/*.snupkg /artifacts/ || true
|
||||||
|
|
||||||
|
- name: Test solution
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet test -c ${CONFIGURATION} --no-build --nologo
|
||||||
|
|
||||||
|
- name: Publish documentation
|
||||||
|
env:
|
||||||
|
DOCFX_SOURCE_REPOSITORY_URL: 'https://gitea.am-wd.de/am-wd/common'
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
/dotnet-tools/docfx metadata docs/docfx.json
|
||||||
|
/dotnet-tools/docfx build docs/docfx.json
|
||||||
|
tar -C "${{ gitea.workspace }}/docs/_site" -czf "/artifacts/docs.tar.gz" .
|
||||||
|
curl -sSL --no-progress-meter --user "${{ secrets.DOCS_DEPLOY_USER }}:${{ secrets.DOCS_DEPLOY_PASS }}" -F docs=common -F dump=@/artifacts/docs.tar.gz "${{ vars.DOCS_DEPLOY_URL }}"
|
||||||
@@ -15,6 +15,9 @@ env:
|
|||||||
jobs:
|
jobs:
|
||||||
build-test-deploy:
|
build-test-deploy:
|
||||||
runs-on: ubuntu
|
runs-on: ubuntu
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
shell: bash
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository code
|
- name: Checkout repository code
|
||||||
uses: actions/checkout@v6
|
uses: actions/checkout@v6
|
||||||
@@ -58,4 +61,4 @@ jobs:
|
|||||||
- name: Publish packages
|
- name: Publish packages
|
||||||
run: |
|
run: |
|
||||||
set -ex
|
set -ex
|
||||||
dotnet nuget push -k "${{ secrets.BAGET_APIKEY }}" -s https://nuget.am-wd.de/v3/index.json --skip-duplicate /artifacts/*.nupkg
|
dotnet nuget push -k "${{ secrets.BAGET_APIKEY }}" -s https://nuget.am-wd.de/v3/index.json --skip-duplicate /artifacts/*.nupkg
|
||||||
65
docs/docfx.json
Normal file
65
docs/docfx.json
Normal file
@@ -0,0 +1,65 @@
|
|||||||
|
{
|
||||||
|
"$schema": "https://raw.githubusercontent.com/dotnet/docfx/main/schemas/docfx.schema.json",
|
||||||
|
"metadata": [
|
||||||
|
{
|
||||||
|
"src": [
|
||||||
|
{
|
||||||
|
"src": "../",
|
||||||
|
"files": [
|
||||||
|
"src/AMWD.Common/bin/Release/netstandard2.0/amwd-common.dll",
|
||||||
|
"src/AMWD.Common.AspNetCore/bin/Release/net8.0/amwd-common-aspnetcore.dll",
|
||||||
|
"src/AMWD.Common.EntityFrameworkCore/bin/Release/net8.0/amwd-common-efcore.dll",
|
||||||
|
"src/AMWD.Common.MessagePack/bin/Release/netstandard2.0/amwd-common-msgpack.dll",
|
||||||
|
"src/AMWD.Common.Test/bin/Release/netstandard2.0/amwd-common-test.dll"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"dest": "api",
|
||||||
|
"outputFormat": "apiPage"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"build": {
|
||||||
|
"content": [
|
||||||
|
{
|
||||||
|
"files": [ "**/*.{md,yml}" ],
|
||||||
|
"exclude": [ "_site/**", "obj/**" ]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"resource": [
|
||||||
|
{
|
||||||
|
"files": [ "images/**" ],
|
||||||
|
"exclude": [ "_site/**", "obj/**" ]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"output": "_site",
|
||||||
|
"template": [ "default", "modern", "templates/amwd" ],
|
||||||
|
"postProcessors": ["ExtractSearchIndex"],
|
||||||
|
"globalMetadata": {
|
||||||
|
"_appName": "AM.WD Common",
|
||||||
|
"_appTitle": "A collection of commonly used extensions, etc.",
|
||||||
|
"_appFooter": "<span>© AM.WD — Docs generated using <a href=\"https://dotnet.github.io/docfx\" target=\"_blank\">docfx</a>.</span>",
|
||||||
|
"_appLogoPath": "images/logo.svg",
|
||||||
|
"_appFaviconPath": "images/favicon.ico",
|
||||||
|
"_disableBreadcrumb": true,
|
||||||
|
"_disableContribution": true,
|
||||||
|
"_enableSearch": true,
|
||||||
|
"_enableNewTab": true,
|
||||||
|
"pdf": false
|
||||||
|
},
|
||||||
|
"markdownEngineName": "markdig",
|
||||||
|
"markdownEngineProperties": {
|
||||||
|
"alerts": {
|
||||||
|
"TODO": "alert alert-secondary"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"sitemap": {
|
||||||
|
"baseUrl": "https://docs.am-wd.de/common",
|
||||||
|
"priority": 0.5,
|
||||||
|
"changefreq": "weekly"
|
||||||
|
},
|
||||||
|
"noLangKeyword": false,
|
||||||
|
"keepFileLink": false,
|
||||||
|
"cleanupCacheHistory": false,
|
||||||
|
"disableGitFeatures": true
|
||||||
|
}
|
||||||
|
}
|
||||||
BIN
docs/images/favicon.ico
Normal file
BIN
docs/images/favicon.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 15 KiB |
1
docs/images/logo.svg
Normal file
1
docs/images/logo.svg
Normal file
@@ -0,0 +1 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg width="35" height="35" viewBox="0 0 384 384" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;"><circle cx="192" cy="192" r="172.8" style="fill:#333;"/><g><path d="M146.936,255.996l0,-19.248l-40.376,-0l-13.045,19.248l-39.755,0l78.475,-116.086c5.384,-7.937 12.769,-11.906 22.156,-11.906c7.04,-0 13.148,2.48 18.324,7.441c5.177,4.961 7.765,10.815 7.765,17.562l0,45.442l-33.544,0l0,-21.431l-19.049,27.781l52.593,0l0,51.197l-33.544,0Z" style="fill:#09f;fill-rule:nonzero;"/><path d="M303.881,255.996l-0,-78.978c-4.148,9.128 -7.531,16.536 -10.151,22.225c-9.168,19.447 -18.118,29.17 -26.85,29.17c-8.623,0 -17.518,-9.657 -26.687,-28.972c-3.492,-7.408 -6.93,-14.882 -10.314,-22.423l0,78.978l-26.359,0l0,-102.989c0,-6.879 2.019,-12.766 6.058,-17.661c4.038,-4.895 8.895,-7.342 14.571,-7.342c9.714,-0 19.974,11.112 30.779,33.337c3.93,8.599 7.914,17.198 11.952,25.797c3.384,-7.408 6.822,-14.816 10.314,-22.225c5.239,-11.112 9.987,-19.447 14.244,-25.003c6.112,-7.937 12.17,-11.906 18.173,-11.906c5.676,-0 10.533,2.447 14.571,7.342c4.039,4.895 6.058,10.782 6.058,17.661l0,102.989l-26.359,0Z" style="fill:#09f;fill-rule:nonzero;"/></g></svg>
|
||||||
|
After Width: | Height: | Size: 1.4 KiB |
18
docs/index.md
Normal file
18
docs/index.md
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
---
|
||||||
|
_layout: landing
|
||||||
|
---
|
||||||
|
|
||||||
|
# AM.WD Common
|
||||||
|
|
||||||
|
Over many years, I copied many lines of code over and over again.
|
||||||
|
So I deciced it was time to change something!
|
||||||
|
|
||||||
|
I started my own NuGet package and it grew over time.
|
||||||
|
|
||||||
|
Now I have my own packages with many extensions and "improvements" for my everyday use.
|
||||||
|
|
||||||
|

|
||||||
|

|
||||||
|

|
||||||
|

|
||||||
|

|
||||||
3
docs/templates/amwd/public/main.css
vendored
Normal file
3
docs/templates/amwd/public/main.css
vendored
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
#logo {
|
||||||
|
margin-right: 8px;
|
||||||
|
}
|
||||||
6
docs/toc.yml
Normal file
6
docs/toc.yml
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
- name: API
|
||||||
|
href: api/
|
||||||
|
- name: Git
|
||||||
|
href: https://gitea.am-wd.de/am-wd/common
|
||||||
|
- name: NuGet
|
||||||
|
href: https://nuget.am-wd.de/?q=AMWD.Common
|
||||||
Reference in New Issue
Block a user