Skip to content

Commit ca2bf1e

Browse files
authored
Add GitHub Actions configuration (#201)
* new build system based on NUKE build * support test running on Linux
1 parent 9d7325b commit ca2bf1e

File tree

100 files changed

+1141
-53001
lines changed

Some content is hidden

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

100 files changed

+1141
-53001
lines changed

.gitattributes

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Auto detect text files and perform LF normalization
2+
* text=auto
3+
4+
# Custom for Visual Studio
5+
*.cs diff=csharp
6+
*.sln merge=union
7+
*.csproj merge=union
8+
*.vbproj merge=union
9+
*.fsproj merge=union
10+
*.dbproj merge=union
11+
12+
# Standard to msysgit
13+
*.doc diff=astextplain
14+
*.DOC diff=astextplain
15+
*.docx diff=astextplain
16+
*.DOCX diff=astextplain
17+
*.dot diff=astextplain
18+
*.DOT diff=astextplain
19+
*.pdf diff=astextplain
20+
*.PDF diff=astextplain
21+
*.rtf diff=astextplain
22+
*.RTF diff=astextplain
23+
24+
# make sure *nix stays *nix
25+
*.sh eol=lf
26+
*.conf eol=lf
27+
dotnet-test-nunit eol=lf

.github/workflows/ci.yml

+41
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: ci
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
paths-ignore:
8+
- 'doc/**'
9+
- '*.md'
10+
11+
pull_request:
12+
branches:
13+
- main
14+
paths-ignore:
15+
- 'doc/**'
16+
- '*.md'
17+
18+
jobs:
19+
build-windows:
20+
runs-on: windows-latest
21+
steps:
22+
- uses: actions/checkout@v2
23+
- name: Run './build.cmd ci'
24+
run: ./build.cmd ci
25+
26+
build-linux:
27+
runs-on: ubuntu-latest
28+
steps:
29+
- uses: actions/checkout@v2
30+
- name: Run './build.cmd ci'
31+
run: ./build.sh ci
32+
33+
publish:
34+
runs-on: ubuntu-latest
35+
needs: [ build-windows, build-linux ]
36+
steps:
37+
- uses: actions/checkout@v2
38+
- name: Publish
39+
run: ./build.sh publish
40+
env:
41+
NuGetApiKey: ${{ secrets.NUGET_API_KEY }}

.github/workflows/publish.yml

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*.*.*'
7+
8+
jobs:
9+
build:
10+
11+
runs-on: ubuntu-latest
12+
env:
13+
DOTNET_NOLOGO: true
14+
DOTNET_CLI_TELEMETRY_OPTOUT: 1
15+
16+
steps:
17+
- name: Checkout source code
18+
uses: actions/checkout@v2
19+
20+
- name: Setup dotnet 2.1
21+
uses: actions/setup-dotnet@v1
22+
with:
23+
dotnet-version: 2.1.*
24+
25+
- name: Setup dotnet 3.1
26+
uses: actions/setup-dotnet@v1
27+
with:
28+
dotnet-version: 3.1.*
29+
30+
- name: Setup dotnet 5.0
31+
uses: actions/setup-dotnet@v1
32+
with:
33+
dotnet-version: 5.0.*
34+
35+
- name: Test
36+
run: ./build.cmd ci test pack
37+
38+
- name: Push with dotnet
39+
run: dotnet nuget push artifacts/*.*nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -87,3 +87,4 @@ PrecompiledWeb
8787
project.lock.json
8888

8989
BenchmarkDotNet.Artifacts*
90+
/artifacts

.nuke/build.schema.json

+155
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,155 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-04/schema#",
3+
"title": "Build Schema",
4+
"$ref": "#/definitions/build",
5+
"definitions": {
6+
"build": {
7+
"type": "object",
8+
"properties": {
9+
"BuildEms": {
10+
"type": "boolean",
11+
"description": "Build EMS"
12+
},
13+
"Configuration": {
14+
"type": "string",
15+
"description": "Configuration to build - Default is 'Debug' (local) or 'Release' (server)",
16+
"enum": [
17+
"Debug",
18+
"Release"
19+
]
20+
},
21+
"Continue": {
22+
"type": "boolean",
23+
"description": "Indicates to continue a previously failed build attempt"
24+
},
25+
"Help": {
26+
"type": "boolean",
27+
"description": "Shows the help text for this build assembly"
28+
},
29+
"Host": {
30+
"type": "string",
31+
"description": "Host for execution. Default is 'automatic'",
32+
"enum": [
33+
"AppVeyor",
34+
"AzurePipelines",
35+
"Bamboo",
36+
"Bitrise",
37+
"GitHubActions",
38+
"GitLab",
39+
"Jenkins",
40+
"Rider",
41+
"SpaceAutomation",
42+
"TeamCity",
43+
"Terminal",
44+
"TravisCI",
45+
"VisualStudio",
46+
"VSCode"
47+
]
48+
},
49+
"NoLogo": {
50+
"type": "boolean",
51+
"description": "Disables displaying the NUKE logo"
52+
},
53+
"NuGetApiKey": {
54+
"type": "string",
55+
"default": "Secrets must be entered via 'nuke :secret [profile]'"
56+
},
57+
"NuGetSource": {
58+
"type": "string"
59+
},
60+
"Partition": {
61+
"type": "string",
62+
"description": "Partition to use on CI"
63+
},
64+
"Plan": {
65+
"type": "boolean",
66+
"description": "Shows the execution plan (HTML)"
67+
},
68+
"Profile": {
69+
"type": "array",
70+
"description": "Defines the profiles to load",
71+
"items": {
72+
"type": "string"
73+
}
74+
},
75+
"ProjectVersion": {
76+
"type": "string",
77+
"description": "Version"
78+
},
79+
"Root": {
80+
"type": "string",
81+
"description": "Root directory during build execution"
82+
},
83+
"Skip": {
84+
"type": "array",
85+
"description": "List of targets to be skipped. Empty list skips all dependencies",
86+
"items": {
87+
"type": "string",
88+
"enum": [
89+
"Antlr",
90+
"Ci",
91+
"Clean",
92+
"Compile",
93+
"CompileExamples",
94+
"CompileSolution",
95+
"Pack",
96+
"PackBinaries",
97+
"Publish",
98+
"Restore",
99+
"Test"
100+
]
101+
}
102+
},
103+
"Solution": {
104+
"type": "string",
105+
"description": "Path to a solution file that is automatically loaded"
106+
},
107+
"Target": {
108+
"type": "array",
109+
"description": "List of targets to be invoked. Default is '{default_target}'",
110+
"items": {
111+
"type": "string",
112+
"enum": [
113+
"Antlr",
114+
"Ci",
115+
"Clean",
116+
"Compile",
117+
"CompileExamples",
118+
"CompileSolution",
119+
"Pack",
120+
"PackBinaries",
121+
"Publish",
122+
"Restore",
123+
"Test"
124+
]
125+
}
126+
},
127+
"TestFull": {
128+
"type": "boolean"
129+
},
130+
"TestIntegrationData": {
131+
"type": "boolean"
132+
},
133+
"TestIntegrationEms": {
134+
"type": "boolean"
135+
},
136+
"TestIntegrationMsMq": {
137+
"type": "boolean"
138+
},
139+
"TestIntegrationNms": {
140+
"type": "boolean"
141+
},
142+
"Verbosity": {
143+
"type": "string",
144+
"description": "Logging verbosity during build execution. Default is 'Normal'",
145+
"enum": [
146+
"Minimal",
147+
"Normal",
148+
"Quiet",
149+
"Verbose"
150+
]
151+
}
152+
}
153+
}
154+
}
155+
}

.nuke/parameters.json

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"$schema": "./build.schema.json",
3+
"Solution": "Spring.Net.sln"
4+
}

Build.cmd

-23
This file was deleted.

README.md

+1-23
Original file line numberDiff line numberDiff line change
@@ -166,29 +166,7 @@ Documented sample applications can be found in "examples":
166166
VS.NET
167167
------
168168

169-
Visual Studio 2017 is required to open and build the solution. The free community version of Visual Studio should suffice.
170-
171-
For the first time you need to execute `Build.cmd` which will generate `GenCommonAssemblyInfo.cs` file required for builds.
172-
173-
NAnt
174-
----
175-
176-
Build scripts are delivered with the download package.
177-
178-
To build the source and run the unit tests type
179-
180-
build test
181-
182-
If you want to run the build to create strongly signed assemblies you can generate a key file by executing the following command (assuming that sn.exe is properly on your search path):
183-
184-
sn -k Spring.Net.snk
185-
186-
You need to place the Spring.NET.snk file into the root folder of the source tree. All builds are strongly named using this key file when executing the following nant command:
187-
188-
nant -D:project.build.sign=true
189-
190-
InnovaSys Document X! is used to generate the SDK documentation.
191-
169+
Visual Studio 2019 is required to open and build the solution. The free community version of Visual Studio should suffice.
192170

193171
## 8. Support
194172

0 commit comments

Comments
 (0)