Skip to content

Commit 0ccb158

Browse files
authored
Merge pull request #2 from FantasyTeddy/cleanup
Update workflows
2 parents 675a21a + da959a4 commit 0ccb158

File tree

11 files changed

+83
-242
lines changed

11 files changed

+83
-242
lines changed

.documentation/.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,5 @@
66
/**/packages/
77
/**/bin/
88
/**/obj/
9-
_site
9+
/_site
10+
/api

.documentation/api/.manifest

Lines changed: 0 additions & 100 deletions
This file was deleted.

.documentation/api/index.md

Lines changed: 0 additions & 1 deletion
This file was deleted.

.documentation/api/toc.yml

Lines changed: 0 additions & 37 deletions
This file was deleted.

.documentation/docfx.json

Lines changed: 17 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -3,33 +3,23 @@
33
{
44
"src": [
55
{
6-
"files": "Functions.csproj",
7-
"exclude": [
8-
"**/bin/**",
9-
"**/obj/**"
10-
],
11-
"src": "../Functions"
6+
"src": "../Functions",
7+
"files": [
8+
"**/*.csproj"
9+
]
1210
}
1311
],
14-
"dest": "api",
15-
"disableGitFeatures": false,
16-
"disableDefaultFilter": false
12+
"dest": "api"
1713
}
1814
],
1915
"build": {
2016
"content": [
2117
{
2218
"files": [
23-
"api/**.yml",
24-
"api/index.md"
25-
]
26-
},
27-
{
28-
"files": [
29-
"articles/**.md",
30-
"articles/**/toc.yml",
31-
"toc.yml",
32-
"*.md"
19+
"**/*.{md,yml}"
20+
],
21+
"exclude": [
22+
"_site/**"
3323
]
3424
}
3525
],
@@ -40,28 +30,15 @@
4030
]
4131
}
4232
],
43-
"overwrite": [
44-
{
45-
"files": [
46-
"apidoc/**.md"
47-
],
48-
"exclude": [
49-
"obj/**",
50-
"_site/**"
51-
]
52-
}
53-
],
54-
"dest": "_site",
55-
"globalMetadataFiles": [],
56-
"fileMetadataFiles": [],
33+
"output": "_site",
5734
"template": [
58-
"default"
35+
"default",
36+
"modern"
5937
],
60-
"postProcessors": [],
61-
"markdownEngineName": "markdig",
62-
"noLangKeyword": false,
63-
"keepFileLink": false,
64-
"cleanupCacheHistory": false,
65-
"disableGitFeatures": false
38+
"globalMetadata": {
39+
"_appName": "functions-csharp",
40+
"_appTitle": "functions-csharp",
41+
"_enableSearch": true
42+
}
6643
}
6744
}

.documentation/index.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
1-
# realtime-csharp
1+
---
2+
_layout: landing
3+
---
4+
5+
# functions-csharp

.documentation/toc.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
1-
- name: Articles
2-
href: articles/
3-
- name: Api Documentation
1+
- name: API
42
href: api/
5-
homepage: api/index.md

.github/workflows/build-and-test.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Build and Test
2+
3+
on:
4+
push:
5+
branches: [master]
6+
pull_request:
7+
branches: [master]
8+
9+
jobs:
10+
build-and-test:
11+
runs-on: ubuntu-latest
12+
13+
env:
14+
TOKEN: ${{ secrets.TOKEN }}
15+
FUNCTION_ENDPOINT: ${{ secrets.FUNCTION_ENDPOINT }}
16+
17+
steps:
18+
- uses: actions/checkout@v3
19+
20+
- name: Setup .NET
21+
uses: actions/setup-dotnet@v3
22+
with:
23+
dotnet-version: 8.x
24+
25+
- name: Restore dependencies
26+
run: dotnet restore
27+
28+
- name: Build
29+
run: dotnet build --configuration Release --no-restore
30+
31+
- name: Test
32+
run: dotnet test --no-restore

.github/workflows/build-documentation.yaml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,23 @@ jobs:
1010
docs:
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/checkout@v2
13+
- uses: actions/checkout@v3
1414
with:
1515
persist-credentials: false
1616

17-
- uses: nikeee/docfx-action@v1.0.0
18-
name: Build Documentation
17+
- name: Setup .NET
18+
uses: actions/setup-dotnet@v3
1919
with:
20-
args: .documentation/docfx.json
20+
dotnet-version: 8.x
21+
22+
- name: Install docfx
23+
run: dotnet tool update -g docfx
24+
25+
- name: Build documentation
26+
run: docfx .documentation/docfx.json
2127

2228
- name: Deploy 🚀
23-
uses: JamesIves/github-pages-deploy-action@3.7.1
29+
uses: JamesIves/github-pages-deploy-action@v4
2430
with:
25-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26-
BRANCH: gh-pages
27-
FOLDER: .documentation/_site # The folder the action should deploy.
28-
CLEAN: true # Automatically remove deleted files from the deploy branch
31+
folder: .documentation/_site
32+
token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/dotnet-core.yml

Lines changed: 0 additions & 33 deletions
This file was deleted.

0 commit comments

Comments
 (0)