Skip to content

Commit

Permalink
feat: Implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
samtrion committed Mar 25, 2024
1 parent efbefd9 commit 5c6665f
Show file tree
Hide file tree
Showing 31 changed files with 1,494 additions and 87 deletions.
42 changes: 42 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,45 @@ updates:
submodules:
patterns:
- "*"

# Delete after first release

- package-ecosystem: "nuget"
directory: "/"
schedule:
interval: "daily"
commit-message:
prefix: "build(deps)"
labels:
- "dependency-nuget"
open-pull-requests-limit: 50
target-branch: "develop"
# groups:
# coverlet:
# patterns:
# - "coverlet*"
# testcontainers:
# patterns:
# - "testcontainers*"
# verify:
# patterns:
# - "verify*"
# xunit:
# patterns:
# - "xunit"
# - "xunit*"

- package-ecosystem: "gitsubmodule"
directory: "/"
schedule:
interval: "daily"
commit-message:
prefix: "build(mods)"
labels:
- "dependency-gitmodule"
open-pull-requests-limit: 50
target-branch: "develop"
groups:
submodules:
patterns:
- "*"
29 changes: 0 additions & 29 deletions .github/template-sync.yml

This file was deleted.

4 changes: 3 additions & 1 deletion .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,7 @@ jobs:
dotnet-logging: ${{ inputs.dotnet-logging }}
dotnet-version: |
7.x
solution: ###SOLUTION###
solution: ./Extensions.Hosting.WinForms.sln
runs-on-build: windows-latest
runs-on-tests: windows-latest
secrets: inherit
24 changes: 0 additions & 24 deletions .github/workflows/template-sync.yml

This file was deleted.

4 changes: 4 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,8 @@
<Import Project="$(DirEngineeringSettings)src.build.props" Condition=" '$(IsTestableProject)' != 'true' " />
<Import Project="$(DirEngineeringSettings)tests.build.props" Condition=" '$(IsTestableProject)' == 'true' " />

<PropertyGroup>
<_TargetFrameworks>net6.0-windows;net7.0-windows;net8.0-windows</_TargetFrameworks>
</PropertyGroup>

</Project>
33 changes: 18 additions & 15 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,29 +1,32 @@
<Project>

<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
<CentralPackageTransitivePinningEnabled>true</CentralPackageTransitivePinningEnabled>
</PropertyGroup>

<ItemGroup>
<GlobalPackageReference Include="CSharpier.MSBuild" Version="0.26.3" />
<GlobalPackageReference Include="CSharpier.MSBuild" Version="0.27.3" />
<GlobalPackageReference Include="GitVersion.MsBuild" Version="5.12.0" />
<GlobalPackageReference Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="3.3.4" />
<GlobalPackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="8.0.0" />
<GlobalPackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" />
<GlobalPackageReference Include="Microsoft.VisualStudio.Threading.Analyzers" Version="17.8.14" />
<GlobalPackageReference Include="SonarAnalyzer.CSharp" Version="9.16.0.82469" Condition=" '$(BuildingInsideVisualStudio)' == 'true' " />
<GlobalPackageReference Include="Microsoft.VisualStudio.Threading.Analyzers" Version="17.9.28" />
<GlobalPackageReference Include="SonarAnalyzer.CSharp" Version="9.21.0.86780" Condition=" '$(BuildingInsideVisualStudio)' == 'true' " />
</ItemGroup>

<ItemGroup>
<PackageVersion Include="coverlet.collector" Version="6.0.0" />
<PackageVersion Include="coverlet.msbuild" Version="6.0.0" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageVersion Include="coverlet.collector" Version="6.0.1" />
<PackageVersion Include="coverlet.msbuild" Version="6.0.1" />
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="8.0.0" />
<PackageVersion Update="Microsoft.Extensions.Hosting" Version="7.0.1" Condition=" '$(TargetFramework)' == 'net7.0-windows' " />
<PackageVersion Update="Microsoft.Extensions.Hosting" Version="6.0.1" Condition=" '$(TargetFramework)' == 'net6.0-windows' " />
<PackageVersion Include="Microsoft.Extensions.Hosting.Abstractions" Version="8.0.0" />
<PackageVersion Update="Microsoft.Extensions.Hosting.Abstractions" Version="7.0.0" Condition=" '$(TargetFramework)' == 'net7.0-windows' " />
<PackageVersion Update="Microsoft.Extensions.Hosting.Abstractions" Version="6.0.0" Condition=" '$(TargetFramework)' == 'net6.0-windows' " />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.9.0" />
<PackageVersion Include="NetEvolve.Extensions.XUnit" Version="2.0.0" />
<PackageVersion Include="NSubstitute" Version="5.1.0" />
<PackageVersion Include="TngTech.ArchUnitNET.xUnit" Version="0.10.6" />
<PackageVersion Include="Verify.Xunit" Version="22.5.0" />
<PackageVersion Include="xunit" Version="2.6.2" />
<PackageVersion Include="xunit.core" Version="2.6.2" />
<PackageVersion Include="xunit.runner.console" Version="2.6.2" />
<PackageVersion Include="xunit.runner.visualstudio" Version="2.5.4" />
<PackageVersion Include="xunit" Version="2.7.0" />
<PackageVersion Include="xunit.runner.visualstudio" Version="2.5.7" />
</ItemGroup>

</Project>
</Project>
68 changes: 68 additions & 0 deletions Extensions.Hosting.WinForms.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{653A4058-FE7E-4E7D-8F48-CA19874137FD}"
ProjectSection(SolutionItems) = preProject
.editorconfig = .editorconfig
.filenesting.json = .filenesting.json
.gitignore = .gitignore
.gitmodules = .gitmodules
Directory.Build.props = Directory.Build.props
Directory.Build.targets = Directory.Build.targets
Directory.Packages.props = Directory.Packages.props
Directory.Solution.props = Directory.Solution.props
GitVersion.yml = GitVersion.yml
LICENSE = LICENSE
new-project.ps1 = new-project.ps1
nuget.config = nuget.config
README.md = README.md
update-solution.ps1 = update-solution.ps1
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{63A3C280-DDDF-4BC1-9B8F-AC8D9F949B3E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetEvolve.Extensions.Hosting.WinForms", "src\NetEvolve.Extensions.Hosting.WinForms\NetEvolve.Extensions.Hosting.WinForms.csproj", "{5501B170-5917-4568-9EAC-8853D14238A1}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{8A14AF25-8CF0-494E-9D50-2FAE3CC9A50A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetEvolve.Extensions.Hosting.WinForms.Tests.Unit", "tests\NetEvolve.Extensions.Hosting.WinForms.Tests.Unit\NetEvolve.Extensions.Hosting.WinForms.Tests.Unit.csproj", "{F7BA85AD-CBD1-4F99-BC28-42DF1253BAE8}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetEvolve.Extensions.Hosting.WinForms.Tests.Integration", "tests\NetEvolve.Extensions.Hosting.WinForms.Tests.Integration\NetEvolve.Extensions.Hosting.WinForms.Tests.Integration.csproj", "{22F991BF-06C3-4B35-BCA2-DD61959C187F}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetEvolve.Extensions.Hosting.WinForms.Tests.Architecture", "tests\NetEvolve.Extensions.Hosting.WinForms.Tests.Architecture\NetEvolve.Extensions.Hosting.WinForms.Tests.Architecture.csproj", "{DF47FD5F-2F7F-470B-98A2-9C5266AA0FBD}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{5501B170-5917-4568-9EAC-8853D14238A1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5501B170-5917-4568-9EAC-8853D14238A1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5501B170-5917-4568-9EAC-8853D14238A1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5501B170-5917-4568-9EAC-8853D14238A1}.Release|Any CPU.Build.0 = Release|Any CPU
{F7BA85AD-CBD1-4F99-BC28-42DF1253BAE8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F7BA85AD-CBD1-4F99-BC28-42DF1253BAE8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F7BA85AD-CBD1-4F99-BC28-42DF1253BAE8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F7BA85AD-CBD1-4F99-BC28-42DF1253BAE8}.Release|Any CPU.Build.0 = Release|Any CPU
{22F991BF-06C3-4B35-BCA2-DD61959C187F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{22F991BF-06C3-4B35-BCA2-DD61959C187F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{22F991BF-06C3-4B35-BCA2-DD61959C187F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{22F991BF-06C3-4B35-BCA2-DD61959C187F}.Release|Any CPU.Build.0 = Release|Any CPU
{DF47FD5F-2F7F-470B-98A2-9C5266AA0FBD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DF47FD5F-2F7F-470B-98A2-9C5266AA0FBD}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DF47FD5F-2F7F-470B-98A2-9C5266AA0FBD}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DF47FD5F-2F7F-470B-98A2-9C5266AA0FBD}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{5501B170-5917-4568-9EAC-8853D14238A1} = {63A3C280-DDDF-4BC1-9B8F-AC8D9F949B3E}
{F7BA85AD-CBD1-4F99-BC28-42DF1253BAE8} = {8A14AF25-8CF0-494E-9D50-2FAE3CC9A50A}
{22F991BF-06C3-4B35-BCA2-DD61959C187F} = {8A14AF25-8CF0-494E-9D50-2FAE3CC9A50A}
{DF47FD5F-2F7F-470B-98A2-9C5266AA0FBD} = {8A14AF25-8CF0-494E-9D50-2FAE3CC9A50A}
EndGlobalSection
EndGlobal
2 changes: 1 addition & 1 deletion new-project.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ New-Project `
-DisableTests $DisableTests `
-DisableUnitTests $DisableUnitTests `
-DisableIntegrationTests $DisableIntegrationTests `
-SolutionFile "###SOLUTION###" `
-SolutionFile "./Extensions.Hosting.WinForms.sln" `
-OutputDirectory (Get-Location) `
-EnableProjectGrouping $EnableProjectGrouping `
-DisableArchitectureTests $DisableArchitectureTests
17 changes: 0 additions & 17 deletions new-solution.ps1

This file was deleted.

30 changes: 30 additions & 0 deletions src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
namespace NetEvolve.Extensions.Hosting.WinForms;

using System.Threading.Tasks;
using System.Windows.Forms;
using Microsoft.Extensions.DependencyInjection;

public interface IFormularProvider

Check warning on line 7 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider'
{
T GetFormular<T>()

Check warning on line 9 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetFormular<T>()'
where T : Form;

ValueTask<T> GetFormularAsync<T>()

Check warning on line 12 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetFormularAsync<T>()'
where T : Form;

Form GetMainFormular();

Check warning on line 15 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetMainFormular()'

ValueTask<Form> GetMainFormularAsync();

Check warning on line 17 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetMainFormularAsync()'

ValueTask<T> GetScopedFormAsync<T>()

Check warning on line 19 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetScopedFormAsync<T>()'
where T : Form;

ValueTask<T> GetScopedFormAsync<T>(IServiceScope scope)

Check warning on line 22 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetScopedFormAsync<T>(IServiceScope)'
where T : Form;

T GetScopedForm<T>()

Check warning on line 25 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetScopedForm<T>()'
where T : Form;

T GetScopedForm<T>(IServiceScope scope)

Check warning on line 28 in src/NetEvolve.Extensions.Hosting.WinForms/IFormularProvider.cs

View workflow job for this annotation

GitHub Actions / Build & Tests / CodeQL / Run CodeQL

Missing XML comment for publicly visible type or member 'IFormularProvider.GetScopedForm<T>(IServiceScope)'
where T : Form;
}
Loading

0 comments on commit 5c6665f

Please sign in to comment.