diff --git a/templates/nuget-classlib-workflow/.github/workflows/dotnet.yml b/templates/nuget-classlib-workflow/.github/workflows/dotnet.yml deleted file mode 100644 index 06f8f54..0000000 --- a/templates/nuget-classlib-workflow/.github/workflows/dotnet.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: .NET CI/CD - -on: - push: - branches: [ "main" ] - pull_request: - branches: [ "main" ] - -jobs: - build_and_pack: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - - name: Setup .NET Core - uses: actions/setup-dotnet@v4 - with: - dotnet-version: '8.0.x' - - - name: Restore dependencies for class library - run: dotnet restore src/ClassLibraryName/ClassLibraryName.csproj - - - name: Pack library - run: dotnet pack src/ClassLibraryName/ClassLibraryName.csproj --output ./nupkgs - - # Veröffentlichen der NuGet-Pakete - - name: Push NuGet and Symbol Packages - run: | - dotnet nuget push ./nupkgs/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate - dotnet nuget push ./nupkgs/*.snupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate diff --git a/templates/nuget-classlib-workflow/.template.config/template.json b/templates/nuget-classlib-workflow/.template.config/template.json deleted file mode 100644 index 016745a..0000000 --- a/templates/nuget-classlib-workflow/.template.config/template.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "$schema": "http://json.schemastore.org/template", - "author": "Patrick Kurmann", - "classifications": [ - "Kurmann", - "GitHub" - ], - "identity": "Kurmann.ClassLibrary.GitHubWorkfow", - "name": "Kurmann Class Library GitHub Workflow", - "shortName": "nuget-classlib-workflow", - "sourceName": "ClassLibraryName", - "description": "Creates a GitHub Actions workflow for publishing a Kurmann class library to NuGet.org.", - "tags": { - "language": "YAML", - "type": "item" - }, - "preferNameDirectory": true, - "sources": [ - { - "modifiers": [ - { - "exclude": [ - ".vs/**", - ".template_config/**", - "**/bin/**", - "**/obj/**", - "/bin/**", - "/obj/**", - ".git/**", - "Readme.md", - "LICENSE", - "nuget.csproj" - ] - } - ] - } - ] -} \ No newline at end of file diff --git a/templates/nuget-classlib/.template.config/template.json b/templates/nuget-classlib/.template.config/template.json deleted file mode 100644 index 31df4cc..0000000 --- a/templates/nuget-classlib/.template.config/template.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "$schema": "http://json.schemastore.org/template", - "author": "Patrick Kurmann", - "classifications": [ - "Kurmann", - "ClassLibrary" - ], - "identity": "Kurmann.ClassLib", - "name": "Kurmann Class Library Template", - "shortName": "nuget-classlib", - "sourceName": "ClassLibrary", - "description": ".NET Class-Library template for the Kurmann namespace including test project.", - "tags": { - "language": "C#", - "type": "solution" - }, - "preferNameDirectory": true, - "sources": [ - { - "modifiers": [ - { - "exclude": [ - ".vs/**", - ".template_config/**", - "**/bin/**", - "**/obj/**", - "/bin/**", - "/obj/**", - "/TestResults/**", - ".git/**", - "Readme.md", - "LICENSE", - "nuget.csproj" - ] - } - ] - } - ], - "symbols": { - "namespace": { - "type": "parameter", - "description": "The root namespace for the project e.g 'Kurmann.Videoschnitt'", - "defaultValue": "Kurmann", - "replaces": "NamespacePlaceholder" - } - } -} \ No newline at end of file diff --git a/templates/nuget-classlib/ClassLibrary.sln b/templates/nuget-classlib/ClassLibrary.sln deleted file mode 100644 index 017db35..0000000 --- a/templates/nuget-classlib/ClassLibrary.sln +++ /dev/null @@ -1,28 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 17 -VisualStudioVersion = 17.0.31903.59 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ClassLibrary", "ClassLibrary\ClassLibrary.csproj", "{8DE9759E-7D5E-427E-B855-C0DFA18B8816}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tests", "Tests\Tests.csproj", "{726120F6-9DD1-40E2-9DDF-5653315BAF3E}" -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 - {8DE9759E-7D5E-427E-B855-C0DFA18B8816}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {8DE9759E-7D5E-427E-B855-C0DFA18B8816}.Debug|Any CPU.Build.0 = Debug|Any CPU - {8DE9759E-7D5E-427E-B855-C0DFA18B8816}.Release|Any CPU.ActiveCfg = Release|Any CPU - {8DE9759E-7D5E-427E-B855-C0DFA18B8816}.Release|Any CPU.Build.0 = Release|Any CPU - {726120F6-9DD1-40E2-9DDF-5653315BAF3E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {726120F6-9DD1-40E2-9DDF-5653315BAF3E}.Debug|Any CPU.Build.0 = Debug|Any CPU - {726120F6-9DD1-40E2-9DDF-5653315BAF3E}.Release|Any CPU.ActiveCfg = Release|Any CPU - {726120F6-9DD1-40E2-9DDF-5653315BAF3E}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection -EndGlobal diff --git a/templates/nuget-classlib/ClassLibrary/ClassLibrary.csproj b/templates/nuget-classlib/ClassLibrary/ClassLibrary.csproj deleted file mode 100644 index 0bb474d..0000000 --- a/templates/nuget-classlib/ClassLibrary/ClassLibrary.csproj +++ /dev/null @@ -1,45 +0,0 @@ - - - - Dependency - net8.0 - enable - enable - - Kurmann.ClassLibrary - Kurmann.ClassLibrary - Kurmann.ClassLibrary - - - NamespacePlaceholder - - - - - - - - - - - README.md - - - LICENSE - - - PackageIcon.png - - - true - true - content - - - true - snupkg - true - - - - diff --git a/templates/nuget-classlib/ClassLibrary/SampleClass.cs b/templates/nuget-classlib/ClassLibrary/SampleClass.cs deleted file mode 100644 index d232340..0000000 --- a/templates/nuget-classlib/ClassLibrary/SampleClass.cs +++ /dev/null @@ -1,10 +0,0 @@ -namespace NamespacePlaceholder.ClassLibrary; - -public class SampleClass -{ - public required string Id { get; set; } - - public required string LastName { get; set; } - - public string? FirstName { get; set; } -} \ No newline at end of file diff --git a/templates/nuget-classlib/Tests/GlobalUsings.cs b/templates/nuget-classlib/Tests/GlobalUsings.cs deleted file mode 100644 index ab67c7e..0000000 --- a/templates/nuget-classlib/Tests/GlobalUsings.cs +++ /dev/null @@ -1 +0,0 @@ -global using Microsoft.VisualStudio.TestTools.UnitTesting; \ No newline at end of file diff --git a/templates/nuget-classlib/Tests/SampleClassTest.cs b/templates/nuget-classlib/Tests/SampleClassTest.cs deleted file mode 100644 index 1dd61b2..0000000 --- a/templates/nuget-classlib/Tests/SampleClassTest.cs +++ /dev/null @@ -1,28 +0,0 @@ -namespace NamespacePlaceholder.ClassLibrary.Tests; - -[TestClass] -public class SampleClassTest -{ - [TestMethod] - public void CanCreateInstance() - { - // Arrange - var id = "1"; - var LastName = "Kurmann"; - var FirstName = "Patrick"; - - // Act - var entity = new SampleClass - { - Id = id, - LastName = LastName, - FirstName = FirstName - }; - - // Assert - Assert.IsNotNull(entity); - Assert.AreEqual(id, entity.Id); - Assert.AreEqual(LastName, entity.LastName); - Assert.AreEqual(FirstName, entity.FirstName); - } -} \ No newline at end of file diff --git a/templates/nuget-classlib/Tests/Tests.csproj b/templates/nuget-classlib/Tests/Tests.csproj deleted file mode 100644 index 227cb78..0000000 --- a/templates/nuget-classlib/Tests/Tests.csproj +++ /dev/null @@ -1,24 +0,0 @@ - - - - net8.0 - enable - enable - false - true - Kurmann.ClassLibrary.Tests - Kurmann.ClassLibrary.Tests - - - - - - - - - - - - - -