diff --git a/.editorconfig b/.editorconfig
index f0bb9fcf..fba98153 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -16,7 +16,7 @@ charset = utf-8-bom
# XML project files
[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}]
-indent_size = 4
+indent_size = 2
# XML config files
[*.{props,targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}]
@@ -96,16 +96,16 @@ dotnet_naming_symbols.constants.required_modifiers = const
dotnet_naming_style.constant_style.capitalization = pascal_case
-# Static fields are camelCase and start with s_
+# Static fields are camelCase and start with _
dotnet_naming_rule.static_fields_should_be_camel_case.severity = suggestion
dotnet_naming_rule.static_fields_should_be_camel_case.symbols = static_fields
-dotnet_naming_rule.static_fields_should_be_camel_case.style = static_field_style
+dotnet_naming_rule.static_fields_should_be_camel_case.style = instance_field_style
dotnet_naming_symbols.static_fields.applicable_kinds = field
dotnet_naming_symbols.static_fields.required_modifiers = static
dotnet_naming_style.static_field_style.capitalization = camel_case
-dotnet_naming_style.static_field_style.required_prefix = s_
+dotnet_naming_style.static_field_style.required_prefix = _
# Instance fields are camelCase and start with _
dotnet_naming_rule.instance_fields_should_be_camel_case.severity = suggestion
@@ -321,3 +321,16 @@ dotnet_diagnostic.IDE2004.severity = warning
# Not enforced as a build 'warning' for 'VisualStudio' layer due to large number of false positives from https://github.com/dotnet/roslyn-analyzers/issues/3857 and https://github.com/dotnet/roslyn-analyzers/issues/3858
# Additionally, there is a risk of accidentally breaking an internal API that partners rely on though IVT.
dotnet_diagnostic.CA1822.severity = suggestion
+
+###############################################################################
+# Set dotnet analyzer rules to:
+# disable CA1401: P/Invoke method '*' should not be visible
+# disable SYSLIB1054: Mark the method '*' with 'LibraryImportAttribute' instead of 'DllImportAttribute' to generate P/Invoke marshalling code at compile time
+###############################################################################
+[*.cs]
+dotnet_diagnostic.CA1401.severity = silent
+dotnet_diagnostic.SYSLIB1054.severity = silent
+csharp_style_prefer_top_level_statements = true:silent
+csharp_style_prefer_primary_constructors = true:suggestion
+
+dotnet_diagnostic.IDE0130.severity = silent
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 944325d2..eabaa20c 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -33,11 +33,11 @@ jobs:
name: windows-latest
runs-on: windows-latest
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: 'Cache: .nuke/temp, ~/.nuget/packages'
- uses: actions/cache@v3
+ uses: actions/cache@v4
with:
path: |
.nuke/temp
@@ -49,27 +49,27 @@ jobs:
AZURE_DEVOPS_PAT: ${{ secrets.AZURE_DEVOPS_PAT }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: 'Publish: log'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: log
path: artifacts/log
- name: 'Publish: bin'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: bin
path: artifacts/bin
- name: 'Publish: obj'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: obj
path: artifacts/obj
- name: 'Publish: tst'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: tst
path: artifacts/tst
- name: 'Publish: pkg'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: pkg
path: artifacts/pkg
diff --git a/.github/workflows/test-ubuntu.yml b/.github/workflows/test-ubuntu.yml
index 655f00f0..f118f908 100644
--- a/.github/workflows/test-ubuntu.yml
+++ b/.github/workflows/test-ubuntu.yml
@@ -33,11 +33,11 @@ jobs:
name: ubuntu-latest
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: 'Cache: .nuke/temp, ~/.nuget/packages'
- uses: actions/cache@v3
+ uses: actions/cache@v4
with:
path: |
.nuke/temp
@@ -49,22 +49,22 @@ jobs:
AZURE_DEVOPS_PAT: ${{ secrets.AZURE_DEVOPS_PAT }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: 'Publish: log'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: log
path: artifacts/log
- name: 'Publish: bin'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: bin
path: artifacts/bin
- name: 'Publish: obj'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: obj
path: artifacts/obj
- name: 'Publish: tst'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: tst
path: artifacts/tst
diff --git a/.github/workflows/test-windows.yml b/.github/workflows/test-windows.yml
index 18c0984c..6d9331ab 100644
--- a/.github/workflows/test-windows.yml
+++ b/.github/workflows/test-windows.yml
@@ -33,11 +33,11 @@ jobs:
name: windows-latest
runs-on: windows-latest
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: 'Cache: .nuke/temp, ~/.nuget/packages'
- uses: actions/cache@v3
+ uses: actions/cache@v4
with:
path: |
.nuke/temp
@@ -49,22 +49,22 @@ jobs:
AZURE_DEVOPS_PAT: ${{ secrets.AZURE_DEVOPS_PAT }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: 'Publish: log'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: log
path: artifacts/log
- name: 'Publish: bin'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: bin
path: artifacts/bin
- name: 'Publish: obj'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: obj
path: artifacts/obj
- name: 'Publish: tst'
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: tst
path: artifacts/tst
diff --git a/.nuke/build.schema.json b/.nuke/build.schema.json
index b9b464a1..27831484 100644
--- a/.nuke/build.schema.json
+++ b/.nuke/build.schema.json
@@ -1,23 +1,51 @@
{
"$schema": "http://json-schema.org/draft-04/schema#",
- "$ref": "#/definitions/build",
- "title": "Build Schema",
"definitions": {
- "build": {
- "type": "object",
+ "Host": {
+ "type": "string",
+ "enum": [
+ "AppVeyor",
+ "AzurePipelines",
+ "Bamboo",
+ "Bitbucket",
+ "Bitrise",
+ "GitHubActions",
+ "GitLab",
+ "Jenkins",
+ "Rider",
+ "SpaceAutomation",
+ "TeamCity",
+ "Terminal",
+ "TravisCI",
+ "VisualStudio",
+ "VSCode"
+ ]
+ },
+ "ExecutableTarget": {
+ "type": "string",
+ "enum": [
+ "Clean",
+ "Compile",
+ "Generate",
+ "Pack",
+ "Release",
+ "Restore",
+ "Setup",
+ "Test"
+ ]
+ },
+ "Verbosity": {
+ "type": "string",
+ "description": "",
+ "enum": [
+ "Verbose",
+ "Normal",
+ "Minimal",
+ "Quiet"
+ ]
+ },
+ "NukeBuild": {
"properties": {
- "Architecture": {
- "type": "string",
- "description": "Platform architecture to use for testing. Default is the processor architecture of the underlying operating system"
- },
- "Configuration": {
- "type": "string",
- "description": "Configuration to build. Default is 'Debug' (local) or 'Release' (server)",
- "enum": [
- "Debug",
- "Release"
- ]
- },
"Continue": {
"type": "boolean",
"description": "Indicates to continue a previously failed build attempt"
@@ -27,25 +55,8 @@
"description": "Shows the help text for this build assembly"
},
"Host": {
- "type": "string",
"description": "Host for execution. Default is 'automatic'",
- "enum": [
- "AppVeyor",
- "AzurePipelines",
- "Bamboo",
- "Bitbucket",
- "Bitrise",
- "GitHubActions",
- "GitLab",
- "Jenkins",
- "Rider",
- "SpaceAutomation",
- "TeamCity",
- "Terminal",
- "TravisCI",
- "VisualStudio",
- "VSCode"
- ]
+ "$ref": "#/definitions/Host"
},
"NoLogo": {
"type": "boolean",
@@ -74,51 +85,46 @@
"type": "array",
"description": "List of targets to be skipped. Empty list skips all dependencies",
"items": {
- "type": "string",
- "enum": [
- "Clean",
- "Compile",
- "Generate",
- "Pack",
- "Release",
- "Restore",
- "Setup",
- "Test"
- ]
+ "$ref": "#/definitions/ExecutableTarget"
}
},
- "Solution": {
- "type": "string",
- "description": "Path to a solution file that is automatically loaded"
- },
"Target": {
"type": "array",
"description": "List of targets to be invoked. Default is '{default_target}'",
"items": {
- "type": "string",
- "enum": [
- "Clean",
- "Compile",
- "Generate",
- "Pack",
- "Release",
- "Restore",
- "Setup",
- "Test"
- ]
+ "$ref": "#/definitions/ExecutableTarget"
}
},
"Verbosity": {
- "type": "string",
"description": "Logging verbosity during build execution. Default is 'Normal'",
+ "$ref": "#/definitions/Verbosity"
+ }
+ }
+ }
+ },
+ "allOf": [
+ {
+ "properties": {
+ "Architecture": {
+ "type": "string",
+ "description": "Platform architecture to use for testing. Default is the processor architecture of the underlying operating system"
+ },
+ "Configuration": {
+ "type": "string",
+ "description": "Configuration to build. Default is 'Debug' (local) or 'Release' (server)",
"enum": [
- "Minimal",
- "Normal",
- "Quiet",
- "Verbose"
+ "Debug",
+ "Release"
]
+ },
+ "Solution": {
+ "type": "string",
+ "description": "Path to a solution file that is automatically loaded"
}
}
+ },
+ {
+ "$ref": "#/definitions/NukeBuild"
}
- }
+ ]
}
diff --git a/.vscode/launch.json b/.vscode/launch.json
index 5d580050..207788fe 100644
--- a/.vscode/launch.json
+++ b/.vscode/launch.json
@@ -18,9 +18,9 @@
"name": "Launch AverageFrameRate",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/AverageFrameRate/Debug/net6.0/AverageFrameRate",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/AverageFrameRate/${input:Configuration}/${input:CoreClrFramework}/AverageFrameRate",
"args": [],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/AverageFrameRate/Debug/net6.0",
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/AverageFrameRate/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
},
@@ -28,9 +28,9 @@
"name": "Launch BitmapViewer",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/BitmapViewer/Debug/net6.0/BitmapViewer",
- "args": ["Sample.bmp"],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/BitmapViewer/Debug/net6.0",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/BitmapViewer/${input:Configuration}/${input:CoreClrFramework}/BitmapViewer",
+ "args": ["${input:BitMapViewerArg}"],
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/BitmapViewer/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
},
@@ -38,9 +38,9 @@
"name": "Launch ParticleSystem",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/ParticleSystem/Debug/net6.0/ParticleSystem",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/ParticleSystem/${input:Configuration}/${input:CoreClrFramework}/ParticleSystem",
"args": [],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/ParticleSystem/Debug/net6.0",
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/ParticleSystem/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
},
@@ -48,9 +48,9 @@
"name": "Launch PlasmaFractal",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/PlasmaFractal/Debug/net6.0/PlasmaFractal",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/PlasmaFractal/${input:Configuration}/${input:CoreClrFramework}/PlasmaFractal",
"args": [],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/PlasmaFractal/Debug/net6.0",
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/PlasmaFractal/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
},
@@ -58,9 +58,9 @@
"name": "Launch RayTracer",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/RayTracer/Debug/net6.0/RayTracer",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/RayTracer/${input:Configuration}/${input:CoreClrFramework}/RayTracer",
"args": [],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/RayTracer/Debug/net6.0",
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/RayTracer/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
},
@@ -68,9 +68,9 @@
"name": "Launch SwirlStars",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/SwirlStars/Debug/net6.0/SwirlStars",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/SwirlStars/${input:Configuration}/${input:CoreClrFramework}/SwirlStars",
"args": [],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/SwirlStars/Debug/net6.0",
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/SwirlStars/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
},
@@ -78,9 +78,9 @@
"name": "Launch TunnelEffect",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/TunnelEffect/Debug/net6.0/TunnelEffect",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/TunnelEffect/${input:Configuration}/${input:CoreClrFramework}/TunnelEffect",
"args": [],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/TunnelEffect/Debug/net6.0",
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/TunnelEffect/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
},
@@ -88,14 +88,43 @@
"name": "Launch WavePlayer",
"type": "coreclr",
"request": "launch",
- "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/WavePlayer/Debug/net6.0/WavePlayer",
- "args": [],
- "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/WavePlayer/Debug/net6.0",
+ "program": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/WavePlayer/${input:Configuration}/${input:CoreClrFramework}/WavePlayer",
+ "args": ["${input:WavePlayerArg}"],
+ "cwd": "${workspaceFolder:SDL2Sharp}/artifacts/bin/samples/WavePlayer/${input:Configuration}/${input:CoreClrFramework}",
"stopAtEntry": false,
"console": "internalConsole"
}
],
"inputs": [
+ {
+ "id": "Configuration",
+ "description": "Choose which configuration should be used.",
+ "default": "Debug",
+ "type": "pickString",
+ "options": [
+ "Debug",
+ "Release"
+ ]
+ },
+ {
+ "id": "Architecture",
+ "description": "Choose which architecture should be used.",
+ "default": "x64",
+ "type": "pickString",
+ "options": [
+ "x86",
+ "x64"
+ ]
+ },
+ {
+ "id": "CoreClrFramework",
+ "description": "Choose which .NET target framework should be used.",
+ "default": "net8.0",
+ "type": "pickString",
+ "options": [
+ "net8.0"
+ ]
+ },
{
"id": "NukeBuildTargets",
"description": "Choose which target to build",
@@ -110,6 +139,18 @@
"Test",
"Pack",
]
+ },
+ {
+ "id": "BitMapViewerArg",
+ "description": "Specify the filename of the bitmap to view",
+ "default": "Sample.bmp",
+ "type": "promptString"
+ },
+ {
+ "id": "WavePlayerArg",
+ "description": "Specify the filename of the WAVE file to play.",
+ "default": "Roland-GR-1-Trumpet-C5.wav",
+ "type": "promptString"
}
]
}
\ No newline at end of file
diff --git a/Directory.Build.props b/Directory.Build.props
index 50e9bc71..80f2397c 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -70,5 +70,4 @@
$(DefaultItemExcludes);obj\**
-
\ No newline at end of file
diff --git a/Directory.Build.targets b/Directory.Build.targets
index 4995884e..d6959465 100644
--- a/Directory.Build.targets
+++ b/Directory.Build.targets
@@ -35,17 +35,16 @@
-
+
all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
+
all
-
+
all
-
+
all
diff --git a/Directory.Packages.props b/Directory.Packages.props
new file mode 100644
index 00000000..44bde376
--- /dev/null
+++ b/Directory.Packages.props
@@ -0,0 +1,24 @@
+
+
+ true
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GitVersion.yml b/GitVersion.yml
index d43e1d22..2009e3d1 100644
--- a/GitVersion.yml
+++ b/GitVersion.yml
@@ -1,4 +1,5 @@
mode: ContinuousDeployment
+next-version: 0.4.0
branches: {}
ignore:
sha: []
diff --git a/SDL2Sharp.sln b/SDL2Sharp.sln
index 05bb3947..23c11dd4 100644
--- a/SDL2Sharp.sln
+++ b/SDL2Sharp.sln
@@ -5,7 +5,7 @@ VisualStudioVersion = 17.1.32319.34
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SDL2Sharp", "sources\SDL2Sharp\SDL2Sharp.csproj", "{648556E3-AFD4-4432-8424-89EED2126F82}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SDL2Sharp.UnitTests", "tests\SDL2Sharp.UnitTests\SDL2Sharp.UnitTests.csproj", "{0EA1CB52-0E1E-4EEC-80B5-5EA37F436EAF}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SDL2Sharp.Tests", "tests\SDL2Sharp.Tests\SDL2Sharp.Tests.csproj", "{0EA1CB52-0E1E-4EEC-80B5-5EA37F436EAF}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "sources", "sources", "{1CCF39F1-02DD-4E9C-B1C2-614715E9EDB0}"
ProjectSection(SolutionItems) = preProject
@@ -29,7 +29,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "samples", "samples", "{3B30
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SDL2Sharp.Interop", "sources\SDL2Sharp.Interop\SDL2Sharp.Interop.csproj", "{A03FB552-F079-4852-8E1A-6ADD6C1BD3A8}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SDL2Sharp.Interop.UnitTests", "tests\SDL2Sharp.Interop.UnitTests\SDL2Sharp.Interop.UnitTests.csproj", "{C4E13408-B833-4B51-BC7B-BABBC759FB1B}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SDL2Sharp.Interop.Tests", "tests\SDL2Sharp.Interop.Tests\SDL2Sharp.Interop.Tests.csproj", "{C4E13408-B833-4B51-BC7B-BABBC759FB1B}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".root", ".root", "{5E4EF724-335F-42C6-A2ED-4DFECD530B7F}"
ProjectSection(SolutionItems) = preProject
@@ -75,8 +75,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".config", ".config", "{8869
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "RayTracer", "samples\RayTracer\RayTracer.csproj", "{A39F687C-F374-461F-A949-FA7BFFB6ADFC}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SDL2Sharp.Extensions", "sources\SDL2Sharp.Extensions\SDL2Sharp.Extensions.csproj", "{AEA6EAFA-AB09-4B19-A103-DDD7E672D506}"
-EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SwirlStars", "samples\SwirlStars\SwirlStars.csproj", "{B8107CDD-068A-451A-86A3-0C33BCEB4F99}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Build", "build\Build\Build.csproj", "{6B61E97E-DF1B-4AE2-A52D-47034759F00E}"
@@ -133,10 +131,6 @@ Global
{A39F687C-F374-461F-A949-FA7BFFB6ADFC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A39F687C-F374-461F-A949-FA7BFFB6ADFC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A39F687C-F374-461F-A949-FA7BFFB6ADFC}.Release|Any CPU.Build.0 = Release|Any CPU
- {AEA6EAFA-AB09-4B19-A103-DDD7E672D506}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {AEA6EAFA-AB09-4B19-A103-DDD7E672D506}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {AEA6EAFA-AB09-4B19-A103-DDD7E672D506}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {AEA6EAFA-AB09-4B19-A103-DDD7E672D506}.Release|Any CPU.Build.0 = Release|Any CPU
{B8107CDD-068A-451A-86A3-0C33BCEB4F99}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B8107CDD-068A-451A-86A3-0C33BCEB4F99}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B8107CDD-068A-451A-86A3-0C33BCEB4F99}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -160,7 +154,6 @@ Global
{73FBFF5C-8D51-48C6-9321-0A9532864E32} = {3B3053A4-91F3-4C66-A6A9-773B6CEEE34C}
{629C4F2E-29C2-417A-BB3C-E52EA33CD365} = {3B3053A4-91F3-4C66-A6A9-773B6CEEE34C}
{A39F687C-F374-461F-A949-FA7BFFB6ADFC} = {3B3053A4-91F3-4C66-A6A9-773B6CEEE34C}
- {AEA6EAFA-AB09-4B19-A103-DDD7E672D506} = {1CCF39F1-02DD-4E9C-B1C2-614715E9EDB0}
{B8107CDD-068A-451A-86A3-0C33BCEB4F99} = {3B3053A4-91F3-4C66-A6A9-773B6CEEE34C}
{6B61E97E-DF1B-4AE2-A52D-47034759F00E} = {9966EF4F-44DE-48FF-964C-B2A7DD157128}
EndGlobalSection
diff --git a/build.ps1 b/build.ps1
index 92f7b642..05176f18 100644
--- a/build.ps1
+++ b/build.ps1
@@ -18,7 +18,7 @@ $TempDirectory = "$PSScriptRoot\\.nuke\temp"
$DotNetGlobalFile = "$PSScriptRoot\\global.json"
$DotNetInstallUrl = "https://dot.net/v1/dotnet-install.ps1"
-$DotNetChannel = "LTS"
+$DotNetChannel = "STS"
$env:DOTNET_CLI_TELEMETRY_OPTOUT = 1
$env:DOTNET_NOLOGO = 1
@@ -65,11 +65,6 @@ else {
Write-Output "Microsoft (R) .NET SDK version $(& $env:DOTNET_EXE --version)"
-# Install the Azure Artifacts Credential Provider for non-server builds
-if ($null -eq $env:GITHUB_ACTIONS -and $null -eq $env:TF_BUILD) {
- Invoke-Expression "& { $(Invoke-RestMethod https://aka.ms/install-artifacts-credprovider.ps1) } -AddNetfx"
-}
-
if (Test-Path env:NUKE_ENTERPRISE_TOKEN) {
& $env:DOTNET_EXE nuget remove source "nuke-enterprise" > $null
& $env:DOTNET_EXE nuget add source "https://f.feedz.io/nuke/enterprise/nuget" --name "nuke-enterprise" --username "PAT" --password $env:NUKE_ENTERPRISE_TOKEN > $null
diff --git a/build.sh b/build.sh
index 84615897..57d4d159 100755
--- a/build.sh
+++ b/build.sh
@@ -14,11 +14,9 @@ TEMP_DIRECTORY="$SCRIPT_DIR//.nuke/temp"
DOTNET_GLOBAL_FILE="$SCRIPT_DIR//global.json"
DOTNET_INSTALL_URL="https://dot.net/v1/dotnet-install.sh"
-DOTNET_CHANNEL="LTS"
+DOTNET_CHANNEL="STS"
export DOTNET_CLI_TELEMETRY_OPTOUT=1
-export DOTNET_MULTILEVEL_LOOKUP=1
-export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
export DOTNET_NOLOGO=1
###########################################################################
@@ -60,24 +58,10 @@ fi
echo "Microsoft (R) .NET SDK version $("$DOTNET_EXE" --version)"
-# Install the Azure Artifacts Credential Provider for non-server builds
-if [[ ! -v GITHUB_ACTIONS && ! -v TF_BUILD ]]; then
- sh -c "$(curl -fsSL https://aka.ms/install-artifacts-credprovider.sh)"
-fi
-
if [[ ! -z ${NUKE_ENTERPRISE_TOKEN+x} && "$NUKE_ENTERPRISE_TOKEN" != "" ]]; then
"$DOTNET_EXE" nuget remove source "nuke-enterprise" &>/dev/null || true
"$DOTNET_EXE" nuget add source "https://f.feedz.io/nuke/enterprise/nuget" --name "nuke-enterprise" --username "PAT" --password "$NUKE_ENTERPRISE_TOKEN" --store-password-in-clear-text &>/dev/null || true
fi
-# Install Mono
-#sudo apt install ca-certificates gnupg
-#sudo gpg --homedir /tmp --no-default-keyring --keyring /usr/share/keyrings/mono-official-archive-keyring.gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
-#echo "deb [signed-by=/usr/share/keyrings/mono-official-archive-keyring.gpg] https://download.mono-project.com/repo/ubuntu stable-focal main" | sudo tee /etc/apt/sources.list.d/mono-official-stable.list
-#sudo apt update
-#sudo apt install mono-devel
-
-# Restore, build, and run!
-"$DOTNET_EXE" restore --interactive
"$DOTNET_EXE" build "$BUILD_PROJECT_FILE" /nodeReuse:false /p:UseSharedCompilation=false -nologo -clp:NoSummary --verbosity quiet
"$DOTNET_EXE" run --project "$BUILD_PROJECT_FILE" --no-build -- "$@"
diff --git a/build/Build/Build.csproj b/build/Build/Build.csproj
index ea468012..af81ffe0 100644
--- a/build/Build/Build.csproj
+++ b/build/Build/Build.csproj
@@ -12,11 +12,11 @@
-
+
-
+
diff --git a/build/Build/ClangSharpPInvokeGenerator.Generated.cs b/build/Build/ClangSharpPInvokeGenerator.Generated.cs
index 898ec121..2d59a6c1 100644
--- a/build/Build/ClangSharpPInvokeGenerator.Generated.cs
+++ b/build/Build/ClangSharpPInvokeGenerator.Generated.cs
@@ -17,2742 +17,784 @@
namespace Nuke.Common.Tools.ClangSharpPInvokeGenerator;
-///
-/// ClangSharp P/Invoke Binding Generator is a tool for generating strongly-typed safe bindings written in C# for .NET and Mono.
-/// For more details, visit the official website.
-///
+/// ClangSharp P/Invoke Binding Generator is a tool for generating strongly-typed safe bindings written in C# for .NET and Mono.
For more details, visit the official website.
[PublicAPI]
[ExcludeFromCodeCoverage]
-[NuGetPackageRequirement(ClangSharpPInvokeGeneratorPackageId)]
-public partial class ClangSharpPInvokeGeneratorTasks
- : IRequireNuGetPackage
+[NuGetTool(Id = PackageId, Executable = PackageExecutable)]
+public partial class ClangSharpPInvokeGeneratorTasks : ToolTasks, IRequireNuGetPackage
{
- public const string ClangSharpPInvokeGeneratorPackageId = "ClangSharpPInvokeGenerator";
- ///
- /// Path to the ClangSharpPInvokeGenerator executable.
- ///
- public static string ClangSharpPInvokeGeneratorPath =>
- ToolPathResolver.TryGetEnvironmentExecutable("CLANGSHARPPINVOKEGENERATOR_EXE") ??
- NuGetToolPathResolver.GetPackageExecutable("ClangSharpPInvokeGenerator", "ClangSharpPInvokeGenerator.dll");
- public static Action ClangSharpPInvokeGeneratorLogger { get; set; } = ProcessTasks.DefaultLogger;
- public static Action ClangSharpPInvokeGeneratorExitHandler { get; set; } = CustomExitHandler;
- ///
- /// ClangSharp P/Invoke Binding Generator is a tool for generating strongly-typed safe bindings written in C# for .NET and Mono.
- /// For more details, visit the official website.
- ///
- public static IReadOnlyCollection