mirror of
https://github.com/XFox111/SimpleOTP.git
synced 2026-04-22 08:00:45 +03:00
Major: support for .NET 9 (#26)
* Updated target to net9.0 * Merged net8.0 and net9.0 targets * Updated workflows
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
{
|
{
|
||||||
"name": "SimpleOTP",
|
"name": "SimpleOTP",
|
||||||
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
|
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
|
||||||
"image": "mcr.microsoft.com/devcontainers/dotnet:1-8.0",
|
"image": "mcr.microsoft.com/devcontainers/dotnet:1-9.0",
|
||||||
|
|
||||||
// Features to add to the dev container. More info: https://containers.dev/features.
|
// Features to add to the dev container. More info: https://containers.dev/features.
|
||||||
// "features": {},
|
// "features": {},
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ name: "CodeQL"
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [ "main" ]
|
branches: [ "main", "next" ]
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '**.md'
|
- '**.md'
|
||||||
- 'LICENSE'
|
- 'LICENSE'
|
||||||
@@ -19,7 +19,7 @@ on:
|
|||||||
- '.assets/*'
|
- '.assets/*'
|
||||||
pull_request:
|
pull_request:
|
||||||
# The branches below must be a subset of the branches above
|
# The branches below must be a subset of the branches above
|
||||||
branches: [ "main" ]
|
branches: [ "main", "next" ]
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '**.md'
|
- '**.md'
|
||||||
- 'LICENSE'
|
- 'LICENSE'
|
||||||
@@ -66,8 +66,16 @@ jobs:
|
|||||||
|
|
||||||
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
||||||
# If this step fails, then you should remove it and run the build manually (see below)
|
# If this step fails, then you should remove it and run the build manually (see below)
|
||||||
- name: Autobuild
|
# - name: Autobuild
|
||||||
uses: github/codeql-action/autobuild@v3
|
# uses: github/codeql-action/autobuild@v3
|
||||||
|
|
||||||
|
- name: Setup .NET
|
||||||
|
uses: actions/setup-dotnet@v4
|
||||||
|
with:
|
||||||
|
dotnet-version: 9.0.x
|
||||||
|
|
||||||
|
- name: Build project
|
||||||
|
run: dotnet build
|
||||||
|
|
||||||
# ℹ️ Command-line programs to run using the OS shell.
|
# ℹ️ Command-line programs to run using the OS shell.
|
||||||
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
|
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ name: "Build workflow"
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [ "main" ]
|
branches: [ "main", "next" ]
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.md"
|
- "**.md"
|
||||||
- "LICENSE"
|
- "LICENSE"
|
||||||
@@ -12,7 +12,7 @@ on:
|
|||||||
- ".devcontainer/*"
|
- ".devcontainer/*"
|
||||||
- "!.github/workflows/pr-workflow.yml"
|
- "!.github/workflows/pr-workflow.yml"
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ "main" ]
|
branches: [ "main", "next" ]
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.md"
|
- "**.md"
|
||||||
- "LICENSE"
|
- "LICENSE"
|
||||||
@@ -33,7 +33,7 @@ jobs:
|
|||||||
- name: Setup .NET
|
- name: Setup .NET
|
||||||
uses: actions/setup-dotnet@v4
|
uses: actions/setup-dotnet@v4
|
||||||
with:
|
with:
|
||||||
dotnet-version: 8.0.x
|
dotnet-version: 9.0.x
|
||||||
|
|
||||||
- run: dotnet restore
|
- run: dotnet restore
|
||||||
- run: dotnet build --no-restore
|
- run: dotnet build --no-restore
|
||||||
@@ -46,7 +46,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
name: SimpleOTP
|
name: SimpleOTP
|
||||||
path: libraries/SimpleOTP/bin/Debug/EugeneFox.SimpleOTP*.*nupkg
|
path: libraries/SimpleOTP/bin/Debug/EugeneFox.SimpleOTP*.*nupkg
|
||||||
|
|
||||||
- name: Drop SimpleOTP.DependencyInjection
|
- name: Drop SimpleOTP.DependencyInjection
|
||||||
uses: actions/upload-artifact@main
|
uses: actions/upload-artifact@main
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ jobs:
|
|||||||
- name: Setup .NET
|
- name: Setup .NET
|
||||||
uses: actions/setup-dotnet@v4
|
uses: actions/setup-dotnet@v4
|
||||||
with:
|
with:
|
||||||
dotnet-version: 8.0.x
|
dotnet-version: 9.0.x
|
||||||
|
|
||||||
- run: dotnet restore
|
- run: dotnet restore
|
||||||
- run: dotnet pack
|
- run: dotnet pack
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net8.0</TargetFramework>
|
<TargetFramework>net9.0</TargetFramework>
|
||||||
<ImplicitUsings>enable</ImplicitUsings>
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
|
|
||||||
@@ -10,7 +10,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.11.1" />
|
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.12.0" />
|
||||||
<PackageReference Include="NUnit" Version="4.2.2" />
|
<PackageReference Include="NUnit" Version="4.2.2" />
|
||||||
<PackageReference Include="NUnit3TestAdapter" Version="4.6.0" />
|
<PackageReference Include="NUnit3TestAdapter" Version="4.6.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net8.0</TargetFramework>
|
<TargetFrameworks>net8.0;net9.0</TargetFrameworks>
|
||||||
<ImplicitUsings>enable</ImplicitUsings>
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<PackageId>EugeneFox.SimpleOTP.DependencyInjection</PackageId>
|
<PackageId>EugeneFox.SimpleOTP.DependencyInjection</PackageId>
|
||||||
<Version>8.0.0.0</Version>
|
<Version>9.0.0.0</Version>
|
||||||
<Authors>Eugene Fox</Authors>
|
<Authors>Eugene Fox</Authors>
|
||||||
<Copyright>Copyright © Eugene Fox 2024</Copyright>
|
<Copyright>Copyright © Eugene Fox 2024</Copyright>
|
||||||
<NeutralLanguage>en-US</NeutralLanguage>
|
<NeutralLanguage>en-US</NeutralLanguage>
|
||||||
@@ -37,7 +37,7 @@
|
|||||||
service in your application.
|
service in your application.
|
||||||
</Description>
|
</Description>
|
||||||
<PackageReleaseNotes>
|
<PackageReleaseNotes>
|
||||||
Initial release. See README.md for details.
|
New major version for .NET 9
|
||||||
</PackageReleaseNotes>
|
</PackageReleaseNotes>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
@@ -57,9 +57,9 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="8.0.*" />
|
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="9.0.*" />
|
||||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions"
|
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions"
|
||||||
Version="8.0.*" />
|
Version="9.0.*" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -2,8 +2,6 @@ using System.Security.Cryptography;
|
|||||||
|
|
||||||
namespace SimpleOTP;
|
namespace SimpleOTP;
|
||||||
|
|
||||||
// TODO: Add tests
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Represents an abstract class for generating and validating One-Time Passwords (OTP).
|
/// Represents an abstract class for generating and validating One-Time Passwords (OTP).
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net8.0</TargetFramework>
|
<TargetFrameworks>net8.0;net9.0</TargetFrameworks>
|
||||||
<ImplicitUsings>enable</ImplicitUsings>
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<PackageId>EugeneFox.SimpleOTP</PackageId>
|
<PackageId>EugeneFox.SimpleOTP</PackageId>
|
||||||
<Version>8.0.0.0</Version>
|
<Version>9.0.0.0</Version>
|
||||||
<Authors>Eugene Fox</Authors>
|
<Authors>Eugene Fox</Authors>
|
||||||
<Copyright>Copyright © Eugene Fox 2024</Copyright>
|
<Copyright>Copyright © Eugene Fox 2024</Copyright>
|
||||||
<NeutralLanguage>en-US</NeutralLanguage>
|
<NeutralLanguage>en-US</NeutralLanguage>
|
||||||
@@ -35,7 +35,7 @@
|
|||||||
Feature-rich, fast, and customizable library for implementation TOTP/HOTP authenticators and validators.
|
Feature-rich, fast, and customizable library for implementation TOTP/HOTP authenticators and validators.
|
||||||
</Description>
|
</Description>
|
||||||
<PackageReleaseNotes>
|
<PackageReleaseNotes>
|
||||||
(BREAKING CHANGE) Complete overhaul of the library. See https://github.com/XFox111/SimpleOTP/releases/tag/2.0.0 for more details.
|
New major version for .NET 9
|
||||||
</PackageReleaseNotes>
|
</PackageReleaseNotes>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user